Why Doesn't This Python Program Work?
|
07-25-2024, 04:56 AM
(This post was last modified: 07-25-2024 04:57 AM by toml_12953.)
Post: #1
|
|||
|
|||
Why Doesn't This Python Program Work?
The following program works when I put it in a PPL wrapper but not from the Python app. In the Python app, it doesn't draw anything, it just prints the elapsed time. I can't figure out why. Can you?
Code: from hpprime import * Tom L Cui bono? |
|||
07-25-2024, 11:39 AM
Post: #2
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
It seems that the graphic functions for Cartesian coordinates do not work directly from the Python application. Removing the '_c' suffix from fillrect_c and pixon_c makes the graphics appear.
Piotr Kowalewski |
|||
07-25-2024, 12:52 PM
Post: #3
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
(07-25-2024 11:39 AM)komame Wrote: It seems that the graphic functions for Cartesian coordinates do not work directly from the Python application. Removing the '_c' suffix from fillrect_c and pixon_c makes the graphics appear. That's a pity. Thanks for the tip. It's working fine now. I also had to reverse the Y-Axis manually. Tom L Cui bono? |
|||
07-26-2024, 02:53 AM
Post: #4
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
I've found out that, in the latest Betas, set_cartesian has no effect and the cartesian versions of the graphics commands don't work. This is both in the Python app and a PPL wrapper. My code worked perfectly before the Beta but now I'll have to wait for more fixes. This is a fairly major issue. It's very handy to define your own coordinates rather than have to calculate pixel positions on your own.
Tom L Cui bono? |
|||
07-26-2024, 03:47 PM
(This post was last modified: 07-26-2024 04:07 PM by komame.)
Post: #5
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
(07-26-2024 02:53 AM)toml_12953 Wrote: I've found out that, in the latest Betas, set_cartesian has no effect and the cartesian versions of the graphics commands don't work. [...] My code worked perfectly before the Beta but now I'll have to wait for more fixes. I just downgraded my G2 to the latest public firmware 14730, and it also doesn't work there, both through the PPL wrapper and in the Python app. I also checked the Virtual Calculator for Windows, and it doesn't work there either. Are you sure this ever worked in Python on Prime (I haven't checked on versions older than 14730)? EDIT: Here are also Günter's tests for an earlier beta version, and as you can see, fillrect_c was already not working properly at that time. Piotr Kowalewski |
|||
08-09-2024, 06:34 AM
Post: #6
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
(07-26-2024 02:53 AM)toml_12953 Wrote: ... the cartesian versions of the graphics commands don't work. ... It's very handy to define your own coordinates rather than have to calculate pixel positions on your own. Thanks for bringing this up. A few tickets have been filed regarding the Cartesian versions (the “_c” variants) of hpprime Python drawing commands ... and those bugs got fixed! ![]() |
|||
08-09-2024, 07:18 AM
Post: #7
|
|||
|
|||
RE: Why Doesn't This Python Program Work?
(08-09-2024 06:34 AM)jte Wrote: ... and those bugs got fixed! This was the most frustrating sentence I've read here quite a few times in the past. Fortunately, the promised update awaits us by the end of August, so hopefully we won't have to wait years for fixes to be published again. :-) Prime G2, 15C CE |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)