www.8devices.com
View unanswered posts | View active topics It is currently 05 May 2024, 05:53



Reply to topic  [ 3 posts ] 
 GPIO spikes on power up 
Author Message

Joined: 27 Jun 2014, 05:53
Posts: 2
Hi!
I am using Carambola2 for my project. I have a buzzer hooked up to one of the GPIO pins using NPN transistor switch.
Then problem is that when I power on the device, buzzer beeps for a very short period of time. I tried every possible GPIO pin (even ones that are pulled-down to the ground). Even pins that are supposed to be bootstrap L spike.
Interestingly it doesn't happen if I hard-reset the board without powering it down.
Could you please help with the fix? What could potentially lead to this behavior? Is it HW (Carambola2 schematic?) or SW issue?
I read SoC datasheet and it seems to me that SoC powers up in the state "all GPIOs are output and are 0". So I feel like it's bootloader or Carambola2 schematic issue.

Thanks!


27 Jun 2014, 08:10
Profile

Joined: 11 Jun 2014, 14:45
Posts: 135
Hi, Katze!

I have checked this with an oscilloscope and during cold boot there is a ~400us long signal, which starts right after the supply voltage rises to turn on the CPU. It's hard to say from just a few quick tests, but it seems that it consists of two ~200us parts, where the first one is just GPIO powering up and the second is initial GPIO configuration (hardware-autoconfiguration??) or just power-up continuation. I doubt that there is anything you could do about these signals themselves (especially the first one), but you could filter them with a capacitor. I tested with 100uF cap (the smallest I could find under my hand :? ) and it did the job, but 100uF is an overkill. You should use a smaller one. Also it would be a bit safer for the GPIO to use an RC filter instead of just a single capacitor.

Hope this helps! If you have any other questions, don't hesitate to ask.


30 Jun 2014, 10:48
Profile

Joined: 27 Jun 2014, 05:53
Posts: 2
Hi!
Thanks for your reply! I was able to get my hands on the oscilloscope over the weekend and discovered the same behavior. I have attached the graph so others can take a look if they want (sorry for a crappy picture - forgot a flash drive at home, had to take pictures using phone). (duplicate here: http://i.imgur.com/TdJpYAh.jpg)
Green line is power, yellow is GPIO. This is exactly as you described. I observed this behavior on all GPIOs.

For the last few days, I have been trying to narrow down this problem ... my plan was to hack the bootloader to set GPIO registers to output-and-all-zeros very early in the bootloader stage ... but the spike seems to be hardware initialization problem, not software. Otherwise it should have reproduced when resetting the board using hard reset button.
Also, SoC datasheet says that output-and-all-zeros is the reset state GPIO registers...
Probably I will have to use RC filter for the Buzzer GPIO.

Thanks!


Attachments:
IMG_20140627_223003 (1).jpg
IMG_20140627_223003 (1).jpg [ 552.13 KiB | Viewed 4138 times ]
02 Jul 2014, 06:34
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron

Protected by Anti-Spam ACP Powered by phpBB® Forum Software © phpBB Group
Designed by ST Software.