Go to advanced search

by itsagoodquestion
Sat Apr 09, 2016 7:19 pm
Forum: C/C++
Topic: Simple Python code to C
Replies: 2
Views: 640

Re: Simple Python code to C

edit--- entire C source is available if you do basic internet search...

https://github.com/tuomasjjrasanen/python-uinput
by itsagoodquestion
Sat Apr 09, 2016 6:58 pm
Forum: C/C++
Topic: One thread got stuck
Replies: 12
Views: 1716

Re: One thread got stuck

And one more thing, the CPU usage when playing normal is only around 59% but when it got stuck the CPU usage could get to 130% Thanks in advance. This is not direct answer to your question, but just observationist, but if you want reduce CPU usage and you use ARM platform is better use the ARM FPU ...
by itsagoodquestion
Fri Apr 08, 2016 3:42 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Interfacing with GSM Module
Replies: 17
Views: 54641

Re: Interfacing with GSM Module

I think its an issue with baud rate on the RPi 3 serial port. I read posts saying that the ttyS0 port's baud rate fluctuates with CPU speed,temp,etc and as the ttyAMA0 serial port has been used for Bluetooth on the pi 3 I can't use that.Any views on this would be very useful!! Sorry but I am not ed...
by itsagoodquestion
Fri Apr 08, 2016 3:37 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: usb problem with GSM modem
Replies: 14
Views: 4954

Re: usb problem with GSM modem

If I am understand everything correctly, all you wants to do is disable modem to reduce power consumption? If this is case there is AT commands you can send (if supported by your firmware, +CFUN= low power mode, turn radio off mode, offline mode, and more) that will physically turn radio off, but ob...
by itsagoodquestion
Thu Apr 07, 2016 3:53 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Interfacing with GSM Module
Replies: 17
Views: 54641

Re: Interfacing with GSM Module

Of course my friend. I see a few things bad with what you say me.. I can see the AT commands being sent You have already send the ATE0 disable echo command so you should not see echo responses. this is indicator that your commands is not being sent/read properly (possibly because you use \r\n termin...
by itsagoodquestion
Wed Apr 06, 2016 3:35 pm
Forum: C/C++
Topic: read keyboard keypress: function keys
Replies: 78
Views: 10839

Re: read keyboard keypress: function keys

I now got an advice in another forum, about using fd = open ("/dev/input/event0", O_RDONLY) If looks very promising, and I will try to follow this approach. Thank you all for your helpful advices! :) hahahahahaha i already tell you this many response ago and i link you copy/paste code sample and yo...
by itsagoodquestion
Wed Apr 06, 2016 2:58 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Interfacing with GSM Module
Replies: 17
Views: 54641

Re: Interfacing with GSM Module

Maybe this helps you but maybe not. 1. do not terminate line with \r\n , use only \r, so instead of "my command\r\n" , send "my command\r" 2. command i normal use to send a sms is 1. AT+CMGW="+1myphonenumber" this is my messgae to send\r response = +CMGW=index // at this point messgae should be save...
by itsagoodquestion
Sun Apr 03, 2016 10:28 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Writing an array of bytes through I2C in one unit
Replies: 5
Views: 1844

Re: Writing an array of bytes through I2C in one unit

I no understand this question so well but using the libc I am no aware of any way to write more than 32 bytes in one call using i2c_smbus_write_block_data() - max 32 bytes (read max size = 32 byte too) if by "arbitrary" you mean any amount of data to write like network socket i no think is possible....
by itsagoodquestion
Sun Apr 03, 2016 6:19 pm
Forum: C/C++
Topic: read keyboard keypress: function keys
Replies: 78
Views: 10839

Re: read keyboard keypress: function keys

hmmm maybe for every programmer is different but for me showkey -ascii / getchar() is not good solution, because your question ask to detect shift/ctrl/alt response and for this method work you have write probably several hundred line of code spaghetti for each of this condition. this method not pos...
by itsagoodquestion
Sun Apr 03, 2016 4:31 pm
Forum: C/C++
Topic: read keyboard keypress: function keys
Replies: 78
Views: 10839

Re: read keyboard keypress: function keys

ahhh yes i almost forget too, is very simple implement this in keyboard filter driver and have user space communicate via ioctl() . you can filter all IRQ read here - https://www.kernel.org/doc/Documentatio ... amming.txt . i know is "too much" but just for the education.
by itsagoodquestion
Sun Apr 03, 2016 4:21 pm
Forum: C/C++
Topic: read keyboard keypress: function keys
Replies: 78
Views: 10839

Re: read keyboard keypress: function keys

Dear friend, I have similar problem and maybe this informations help you. I believe you use the gnome terminal which have key such as f1 - f12 as keyhots. internal gnome message manager no pass messgae down. I propose to use 2 solution, 1 is fast &easy other is maybe 1 -2 hundred of c code. solution...
by itsagoodquestion
Sat Mar 26, 2016 2:20 am
Forum: Python
Topic: Pyobfuscate ?
Replies: 17
Views: 2677

Re: Pyobfuscate ?

"I simply want create any road block I can" If you do this you will make difficult or stop normal motorist from cummuting & this normal, paying motorist will find different road. Search on internet for "reverse python byte code". There is not shortage of information on this topic & I recommend you ...
by itsagoodquestion
Fri Mar 25, 2016 9:15 pm
Forum: Other projects
Topic: New Raspberry Pi Project. Need Help!
Replies: 1
Views: 366

Re: New Raspberry Pi Project. Need Help!

Yes of course the raspberry pi can read heart sensor & handle motors but you need be able to program. You probably better off to find a new girlfriend who live near to you than to sleep with spinning motors though. I cannot believe the people spend 100K USD on that product you show me. Is a very str...
by itsagoodquestion
Fri Mar 25, 2016 7:06 pm
Forum: Python
Topic: Pyobfuscate ?
Replies: 17
Views: 2677

Re: Pyobfuscate ?

You want to stop piracy? 1st thing to know is - YOU WILL LOOSE - . Is not possible to win. Is better for you to forget this idea right now and focus on being creative & productive. Sorry for scream at you hehe but is important to emphasize this. That said, is especially difficult for interpreted lan...
by itsagoodquestion
Wed Mar 23, 2016 3:28 am
Forum: C/C++
Topic: server UDP multiclient non blocking
Replies: 6
Views: 1731

Re: server UDP multiclient non blocking

You can use it on pi same way you will with any other linux OS, and the code is almost identical for Windows too. Method is not unique to rapsberry pi. Maybe I'm wrong but I don't think you will find a copy/pasteable code sample but use the functions I mention you before, I think as long as you know...
by itsagoodquestion
Wed Mar 23, 2016 3:20 am
Forum: C/C++
Topic: Compiled Qt 5.x/4.x static libs?
Replies: 13
Views: 3560

Re: Compiled Qt 5.x/4.x static libs?

my point is that there is no "sudo apt-get install qtdynamiclibs"... For me static compile is only solution. Millions on others Qt coders too. This why this option exists...
by itsagoodquestion
Tue Mar 22, 2016 6:56 pm
Forum: C/C++
Topic: how to pass proprietary GPS data: C prog => Navit or OSM?
Replies: 10
Views: 2496

Re: how to pass proprietary GPS data: C prog => Navit or OSM

I sorry but this is not direct answer to your question - only my opinion. I do very similar project some years ago. You can use googlemaps in QtWebView and you pass GPS coordinates in URL to google. Is very easy and in my humble opinion it looks much better than navit and have many more options of c...
by itsagoodquestion
Tue Mar 22, 2016 6:47 pm
Forum: C/C++
Topic: server UDP multiclient non blocking
Replies: 6
Views: 1731

Re: server UDP multiclient non blocking

Hello friend, So I think is - always - better use non-blocking sockets - great decision!!! On linux for non-blocking sockets you must to use fcntl() function after initial call to connect()/accept() , then you call select() w/struct timeval to tell how many seconds/milseconds to wait. You must to do...
by itsagoodquestion
Tue Mar 22, 2016 6:33 pm
Forum: C/C++
Topic: Compiled Qt 5.x/4.x static libs?
Replies: 13
Views: 3560

Re: Compiled Qt 5.x/4.x static libs?

Peter, sudo apt-get install QtCreator to run binary is very bad solution. Friend, I appreciate your want to help me but your information is wrong. Read this so u understand more. http://stackoverflow.com/questions/934950/how-to-make-binary-distribution-of-qt-application-for-linux http://stackoverflo...
by itsagoodquestion
Sat Mar 19, 2016 2:02 pm
Forum: C/C++
Topic: Compiled Qt 5.x/4.x static libs?
Replies: 13
Views: 3560

Re: Compiled Qt 5.x/4.x static libs?

When I distro all the dynamic libraries, it's around 30 MB, then I have to write an installer for the dynamical libraries and it just becomes a pain. This is why packaging systems like apt https://wiki.debian.org/Apt were invented. You should learn how to use it. PeterO This have nothing to do with...
by itsagoodquestion
Fri Mar 18, 2016 5:08 am
Forum: C/C++
Topic: Tutorials about how to use console for programming
Replies: 6
Views: 1171

Re: Tutorials about how to use console for programming

You know I learned on gdb for x86/x64 desktop linux before this ARM world became popular and is hell using gdb for x64/x86 I hated it, but on ARM gdb isn't so bad since anything important passes through registers, really I only use 3 or 4 commands and that's it, then again I don't do any debugging c...
by itsagoodquestion
Mon Mar 14, 2016 9:49 pm
Forum: C/C++
Topic: How to make a qt demo on raspberry pi with buildroot??
Replies: 2
Views: 2122

Re: How to make a qt demo on raspberry pi with buildroot??

Hello friend, depending on your code Qt can get complicated to do a normal static compile, so a cross compile will require very good understanding of the tools you use, qmake, make, g++, etc. There are guides I've seen to cross compile arm on x86 or x64, but they may or may not be accurate. My net r...

Go to advanced search