Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Combine with another Python script #11

Open
fthmhmt opened this issue May 26, 2019 · 5 comments
Open

Combine with another Python script #11

fthmhmt opened this issue May 26, 2019 · 5 comments
Labels
enhancement New feature or request

Comments

@fthmhmt
Copy link

fthmhmt commented May 26, 2019

Thank you for sharing the code. It is working great!
I am not familiar with python and would like to ask you if you can help me out to combine your code with another one.

An import into your code of this code (https://github.com/Zacki84/Wien-Abfahrtsmonitor) did not give the output to the LED Badge.

Can you give me here a tip how to print output of codes to the LED Badge?

@jnweiger
Copy link
Owner

The basic call sequence in the current version is something like this:

(data, cols) = bitmap_text("Hello World!")
head = header([cols], 4, 0, 0, 0)
pyhidapi.hid_write(dev, head+data)

You need to cut/copy/paste so you have all the parts that are needed, and probably also have to remove some unneeded parts (e.g. the option parser).
All this would be much easier, if the code were a proper python module, of course. Blame me for being lazy in the first place ....

@semaf
Copy link

semaf commented May 26, 2019

All this would be much easier, if the code were a proper python module, of course. Blame me for being lazy in the first place ....

You are right. As module it would be really easier. Hope that you have time to do it very soon.

@jnweiger
Copy link
Owner

Well, I don't intend to save the world all by myself... Patches welcome.

@bensartori
Copy link
Contributor

Hello fthmhmt, there were progress on this topic..., see last comment in #3 and PR #45 .

@bensartori
Copy link
Contributor

Hello @fthmhmt, does it work for you, now (see last comment)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants