hybridfree/eevblog-posts huggingface dataset:
AVR reset pin leakage - Page 1
Forum section: electronics / general

author: ralphd
author_rank: Frequent Contributor
timestamp: May 14, 2015, 03:21:55 pm
content: I've noticed the reset pin of AVRs is usually many 10s of mV lower than Vcc, implying the input impedance is lower than the regular I/O pins. I just measured an ATtiny13A I had plugged into a breadboard:Vcc = 3.434V, RST = 3.257VAccording to the datasheet the reset pullup is around 55KOhm.3.434 - 3.257 = .180V; .18 = I * 55K; .18/55k = I == 3.27uASo, unless I made a mistake in the math, the reset pin leakage current is 3.27uA. Figure 19-3 of the datasheet shows power down (WDT disabled) current @3.5V/25C of 0.2uA. So given my reset pin leakage measurements, does that mean those power numbers are only with the reset pin disabled? If so, that contradicts with the measurements made on a '328:https://www.sparkfun.com/tutorials/309I don't think it's just a bad ATtiny13, since I've measured similar (0.1 - 0.2V below Vcc) on other AVRs like tiny84 and tiny85's.Any ideas what's going on?

author: ralphd
author_rank: Frequent Contributor
timestamp: May 14, 2015, 03:48:04 pm
content: I remembered t13s and t85s have ADC mux in available on the reset pin, which might add to leakage. The t84 doesn't, so just one tested, and @5V leakage is 6.44uA.t84a: 4.99Vcc - 4.70RST = .29 = I * 45K; 290/45 = 6.44uAThe datasheet says 30-60K for the reset pullup, hence the 45K in the leakage calculation.

author: sync
author_rank: Frequent Contributor
timestamp: May 14, 2015, 03:57:16 pm
content: Does your meter have 1Mohm input impedance?3.257V / 1Mohm = 3.257uA

author: hans
author_rank: Super Contributor
timestamp: May 14, 2015, 04:14:44 pm
content: Resistive voltage divider..55k / 1M ohm: 1000k / 1055k * 3.434 = 3.255V55 / 10M ohm: 10000k / 10055k * 3.434 = 3.415VI would recommended measuring the voltage across the resistor itself, not over GND. That way 1M / 55k will still make an error (1M || 55k = 52k), but not nearly as much

author: ralphd
author_rank: Frequent Contributor
timestamp: May 14, 2015, 05:24:10 pm
content: Doh! Forgot about the meter impedance. Measuring between Vcc and RST on the t13a wavers between 0.000 and 0.001V on the meter, so that explains it.
Why do we stop watchdog timer on MSP430 ? - Page 1
Forum section: electronics / general

author: Nhan95
author_rank: Contributor
timestamp: May 14, 2015, 01:41:50 am
content: I see that many programs for MSP430 microcontroller, they usually stop the watchdog timer first:WDTCTL = WDTPW | WDTHOLD; // Stop watchdog timerWhat's watchdog timer and why do have to do that ? Does other MCU have watchdog timer

author: nctnico
author_rank: Super Contributor
timestamp: May 14, 2015, 01:46:39 am
content: IIRC this has something to do with people not wanting to have the watchdog enabled by default. The damn thing is on by default and set to a very short interval which causes trouble with initialisation code (zeroing the memory and copying initialised variables into RAM).

author: c4757p
author_rank: Super Contributor
timestamp: May 14, 2015, 01:49:34 am
content: The purpose of a watchdog timer is to forcibly reset your microcontroller if your code gets stuck for some reason. It has a timeout period, and if you don't poke it during that period, it resets you. You're supposed to stick that poke somewhere in your main loop, preferably with some sanity checks so you only poke it if everything is good.Yes, most microcontrollers have one, but MSP430 is somewhat unique in that it starts up with it enabled by default.
PSoC EMC  - Page 1
Forum section: electronics / general

author: luky315
author_rank: Regular Contributor
timestamp: May 12, 2015, 02:06:35 pm
content: Has anyone experiences with Cypress PSoC in demanding environments (Automotive, Electric Drives, Industrial)?Are they more susceptible to external interferences then "traditional", non configurable microcontrollers?

author: jboard146
author_rank: Contributor
timestamp: May 12, 2015, 07:59:40 pm
content: My understanding is that they are flash based so anything that would kill any other flash based device would PSoC as well. This is just my opinion and have ZERO facts to back this up.What does Cypress say?

author: miguelvp
author_rank: Super Contributor
timestamp: May 13, 2015, 12:44:00 am
content: For what I've seen from their product selector, only the PSoC 1 has Automotive qualified chips, that doesn't mean the other ones (3, 4, 5LP and 4BLE) are not present in cars, but I think they are in non critical applications.Maybe this link helps:http://www.cypress.com/?id=3But I guess it depends what do you have in mind.Use their support links, they are very quick and professional and they don't biteOut of the links in this page, Open a case would probably give you the best response, but you need to register (for free) with them, downside registering is that if you look at any datasheet while signed in, they send you e-mails with a survey even if it's a pdf that you already got before.http://www.cypress.com/?id=4Also check their roadmaps:http://www.cypress.com/?app=search&searchType=advanced&keyword=&rtID=491&id=0&applicationID=0&l=0

author: T3sl4co1l
author_rank: Super Contributor
timestamp: May 13, 2015, 01:54:00 am
content: Not familiar with them myself, but I can't imagine what would be a concern beyond the usual matters -- stable logic levels, solid supply voltage, keep ESD away, etc. Analog parts will have the added restriction of ADC aliasing or RF rectification (bipolar op-amps being most sensitive to the latter, but PSoC stuff might exhibit some effects, too). (And obviously, RF rectification from input protection diodes is always a concern for analog/precision, regardless of what it's going into.)Tim

author: luky315
author_rank: Regular Contributor
timestamp: May 13, 2015, 05:18:00 am
content: At the moment I'm using the Freescale Kinetis KEA with proven good EMC and ESD performance.My question is targeted at (professional) PSoC users which (idealy) passed a EMC certification or something similar with a product containing a PSoC. The reason I ask this because I have had a bad experience in the EMV Lab with a Microcontroller from another manufacturer which was clearly related to the IC itself.
Hi-Tech C Binary/HEX to BCD - Page 1
Forum section: electronics / general

author: singlarrysong
author_rank: Contributor
timestamp: May 16, 2015, 04:15:02 pm
content: Is there any efficient way to convert Binary to Hex in Hi-Tech C compiler?i did not found any macro in the compuilerMy variable is 0-99(Decimal) and im using char, 8bits wide thus 0000 - 0110 0011(binary).The only way I figure out so far is to divide the variable by 10 to get the most significant decimal, but problem found that for the less significant decimal will be trouble as I need add in different constant to the value 10- 99 to make the last 4 bit of the variable exactly shown 0-9 for any value greater than 9.

author: IanB
author_rank: Super Contributor
timestamp: May 16, 2015, 04:27:49 pm
content: What do you mean by "convert"? Do you mean print?Also, from what you wrote, two digits 0-99, and dividing by 10, what do you mean by "Hex"? Do you mean BCD?Your question is very confusing. I don't understand what you trying to do.

author: singlarrysong
author_rank: Contributor
timestamp: May 16, 2015, 04:58:34 pm
content: Sorry about the confusion.I need to print 0-99 on two 7-seg drive by 4511 decoder which decode BCD input to match 7-seg input.And I'll have a char variable that increment or decrement in software.Since in system language it usually binary or hex, thus I would like to know any kinds of method to convert them into BCD. So I can set(print) the output to match the 4511 input.

author: IanB
author_rank: Super Contributor
timestamp: May 16, 2015, 05:07:23 pm
content: You can divide by 10 to get the most significant digit, then you can subtract that from the original number to get the least significant digit. Like this:d1 = n/10; /* n holds original value, d1 is most significant digit */d2 = n - 10*d1; /* d2 is least significant digit */Example:n is 5757/10 is 5 -> first digit57 - 10*5 is 7 -> second digit

author: Someone
author_rank: Super Contributor
timestamp: May 16, 2015, 11:34:18 pm
content: Binary to BCD is a well researched problem, there are many implementations floating around if you use your favourite search engine. Bonus points for finding an algorithm well suited to your target platform and application (which integer divide & multiply most certainly wont be).

author: oPossum
author_rank: Super Contributor
timestamp: May 17, 2015, 10:17:21 am
content: The easy way to do it in C is with the C standard library function div();Code:#include <stdlib.h>int x = 42; // Some number from 0 to 99div_t d = div(x, 10);d.quot is first digitd.rem is second digitthis method can easily be extended to more digitsCode:int x = 1234; // some number from 0 to 9999div_t d = div(x, 1000);d.quot is first digitd = div(d.rem, 100);d.quot is second digitd = div(d.rem, 10);d.quot is third digitd.rem is fourth digit

author: singlarrysong
author_rank: Contributor
timestamp: May 17, 2015, 10:17:48 am
content: Thanks for everyone reply, will look for it in two days time.Recently busy. Sorry about that
WiFi Esp8266 ESP 12 Board - How to use the pins ? - Page 1
Forum section: electronics / general

author: tytower
author_rank: Contributor
timestamp: May 14, 2015, 10:01:37 am
content: So I have an ESP12 board with 16 pins and it would appear the following pins are useable for my sensor input and output.GPIO 2...........edit......now Pin2 in sketch and DHT running properly on it.GPIO 5...........edir......Pin5 and SDAGPIO 4...........edit......Pin4 and SCLGPIO 13GPIO 12GPIO 14GPIO 16.........edit......XPD---| |----RST for DeepSleepADC...............edit......the only Analog pin availableI want to connect firstly a DHT22 sensor which has GND/VCC/DATA wiresWhich pin should I choose for DATA wire and why ? It was connected to pin D2 on an arduino.I want also to connect a BMP180 sensor and its 2 data lines were connected to pins A4 and A5 of the Arduino . Which should I choose and why? SDA and SCL but which pins.So are the GPIO pins analog or digital ? Perhaps I have to set them upIs there a diagram of these ?All help appreciated-

author: TJ232
author_rank: Frequent Contributor
timestamp: May 14, 2015, 06:28:24 pm
content: Hi,Please find attached my wall-hanging GPIO pinout and NodeMCU New I/O TABLE ( Build 20141219 and later)Also, take a look on esp8266-projects.com, esp8266.com, you will find a lot of informations that can help you to start with esp8266.

author: tytower
author_rank: Contributor
timestamp: May 15, 2015, 10:14:07 am
content: Quote from: TJ232 on May 14, 2015, 06:28:24 pmThat was the one I needed thanksI suspect however that this may only relate to Arduino IDE releases 1.6.1 and prior .Downloading IDE 1.6.4 there is a different system of getting the ESP8266 library through preferences and it is also stored in a "packages" directory if you want to find the cpp and h files.I notice most importantly that GPIO2 is addressed as pin 2 in my sketch and this is working for me at present. GPIO4 and 5 are now addressed as pins 4 and 5 and I have used them for I2C . I have not checked the other pins yet but I think this release has fixed them to board numbers.XPD connected to RST through a small capacitor does a great job of putting it into and out of deep sleep.
ESP8266 - MAINS Power Dimmer Module - Page 1
Forum section: electronics / general

author: TJ232
author_rank: Frequent Contributor
timestamp: May 04, 2015, 06:10:12 pm
content: For that ones of you that have already read my articlesWeb Power Switch for MAINSand the :WIFI MPSMv2 MAINS Switch DevBoard, you surely remember that the above modules were ON/OFF switching only.Now it's about time to talk also about DIMMING!MPDMv3 is a MAINS Power Dimmer module with Zero Cross Detection circuit:Zero Cross DetectorFiring the triac test:Youtube Videos:Testing Zero Cross Detector :First test - Dimming a Lamp :For more details:http://www.esp8266-projects.com/2015/05/p3-wifi-mains-power-dimmer-switch-with.html

author: TJ232
author_rank: Frequent Contributor
timestamp: May 07, 2015, 09:17:03 am
content: Second part about the new MAINS Dimmer / Switch Module,Web interface access design an testing

author: linux-works
author_rank: Super Contributor
timestamp: May 07, 2015, 03:11:16 pm
content: (following)zero crossing stuff looks interesting.I also would like to get open hw/sw control over my home lighting. still thinking about how to get it all done and still be in full control (no 'cloud shit', lol).is esp the answer to everything, now? heh. kind of seems like its doing everything

author: Mechanical Menace
author_rank: Super Contributor
timestamp: May 07, 2015, 04:43:11 pm
content: Quote from: linux-works on May 07, 2015, 03:11:16 pmSet up a server on your network instead of the cloud?
Two LED blinkers - Page 1
Forum section: electronics / general

author: technix
author_rank: Super Contributor
timestamp: May 05, 2015, 05:22:31 pm
content: Finally I got that CPLD and the PIC blinking LEDs stably.PIC blinker is just a traditional LED blinking code, equivalent of Arduino's example.CPLD blinker is binary dividing the CPLD eval kit's 50MHz oscillator down to a visible frequency.

author: technix
author_rank: Super Contributor
timestamp: May 06, 2015, 04:42:04 am
content: Quote from: SL4P on May 05, 2015, 10:57:44 pmSorry but I am kind of an introvert and I'd rather spend time & money on projects than be rejected my girls and have my mood worn down.

author: technix
author_rank: Super Contributor
timestamp: May 06, 2015, 04:57:10 am
content: Quote from: SL4P on May 06, 2015, 04:45:49 amHaving been cheated on pretty early on by two girls in a row without ever really have a girlfriend will be a scarring experience. This thread is running off topic.

author: Skimask
author_rank: Super Contributor
timestamp: May 06, 2015, 05:12:47 am
content: Who's running it off topic?

author: obiwanjacobi
author_rank: Super Contributor
timestamp: May 06, 2015, 08:54:52 am
content: The blink-led program is the "Hello World" of the embedded software.It is good to be at that stage, then you know that at least the basics are working.Good luck with (the rest of) your project.

author: technix
author_rank: Super Contributor
timestamp: May 06, 2015, 10:40:45 am
content: Quote from: obiwanjacobi on May 06, 2015, 08:54:52 amThis at least give me some confidence that mt circuit building is correct, and I did in fact got a program in there up and running. I am still new to CPLD and PIC, for now my MCU of choice is still AVR and ARM, but this means more options are open to me now.
[SOLVED] PIC on breadboard: why won't it blink? - Page 1
Forum section: electronics / general

author: technix
author_rank: Super Contributor
timestamp: May 04, 2015, 04:06:37 pm
content: The PICKit arrived and I started experimenting with a few PIC16F72 on a breadboard, starting with a LED blinker.Here is the code:config.hCode:#ifndef CONFIG_H#defineCONFIG_H#define _XTAL_FREQ 16000000 // 16MHz crystal oscillator used#include <pic.h>#include <xc.h>#ifdef MAIN_FILE// Configuration bits#pragma config FOSC = HS // Oscillator Selection bits (HS oscillator)#pragma config WDTE = OFF // Watchdog Timer Enable bit (WDT disabled)#pragma config PWRTE = ON // Power-up Timer Enable bit (PWRT enabled)#pragma config CP = OFF // FLASH Program Memory Code Protection bit (Code protection off)#pragma config BOREN = ON // Brown-out Reset Enable bit (BOR enabled)#endif#endif/* CONFIG_H */main.cCode:#define MAIN_FILE#include "config.h"void main(void){// Make the LED light up.TRISA &= ~0x1;while (1){PORTA |= 0x1;__delay_ms(500);PORTA &= ~0x1;__delay_ms(500);}}I have a 16MHz crystal across pins 9 and 10, power at appropriate pins with a 220nF bypass, and a LED with MOSFET low side switch at pin 2.The blinking is erratic and I am confused at what is going on. 16F72 does not support debugging with PICKit (D'oh!) so pointers please?EDIT: Solved. Two culprits: the pin I used was an analog pin which have to be configured into a digital output first, and I left the RESET pin flapping in the wind.

author: 22swg
author_rank: Frequent Contributor
timestamp: May 04, 2015, 04:22:44 pm
content: Mmmm Check the data sheet page 21 .... ADCON1 ?Edit you dont mention any Xtal 22pf caps

author: Rolo
author_rank: Regular Contributor
timestamp: May 04, 2015, 04:27:27 pm
content: Yes, ADCON, pic's pins often default to analog inputs. And after setting that you should make the port an output.Also when beginning with MCU's disable Brown Out, unless you realy use it.Hope this helps !

author: technix
author_rank: Super Contributor
timestamp: May 04, 2015, 04:51:01 pm
content: Quote from: 22swg on May 04, 2015, 04:22:44 pmThis one worked better, but still erratic:Code:void main(void){// pinMode(PA0, OUTPUT)ADCON1 = 0x6;TRISA &= ~0x1;while (1){PORTA |= 0x1;__delay_ms(500);PORTA &= ~0x1;__delay_ms(500);}}

author: os40la
author_rank: Regular Contributor
timestamp: May 04, 2015, 04:56:29 pm
content: Quote from: technix on May 04, 2015, 04:51:01 pmDo you have a pull-up resistor on the reset pin?

author: technix
author_rank: Super Contributor
timestamp: May 04, 2015, 05:38:56 pm
content: Quote from: os40la on May 04, 2015, 04:56:29 pmDo I need an 1N5819 to protect it against Vpp overloading the power rail?

author: technix
author_rank: Super Contributor
timestamp: May 04, 2015, 06:01:54 pm
content: Quote from: os40la on May 04, 2015, 04:56:29 pmAdded a 6.8k pullup and a 1N5819 protection diode, works like a charm now. Thanks.
12bit 4 to 20ma current loop transmiter - Page 1
Forum section: electronics / general

author: ali_asadzadeh
author_rank: Super Contributor
timestamp: April 29, 2015, 01:19:19 pm
content: Hi,There is a whole lot of dedicated DAC out there for doing the job, But I wonder is there any cheap way of doing it with our 12bit DAC inside the already existing MCU in our board! any ideas are welcome.

author: langwadt
author_rank: Super Contributor
timestamp: April 30, 2015, 12:36:25 pm
content: Quote from: ali_asadzadeh on April 29, 2015, 01:19:19 pmdoes it need to be loop powered?

author: ali_asadzadeh
author_rank: Super Contributor
timestamp: April 30, 2015, 03:09:59 pm
content: Thanks, yes loop power would be nicer.

author: Marco
author_rank: Super Contributor
timestamp: May 01, 2015, 02:42:29 am
content: I think something like this would work (micro, LDO etc on the right, obviously the current consumption of all that combined with the opamp has to be below 4 mA ... could use a buck converter with some input filtering if you need more than 4 mA) :
Does this look like an acceptable PIC16F72 eval kit? - Page 1
Forum section: electronics / general

author: technix
author_rank: Super Contributor
timestamp: April 30, 2015, 01:49:16 pm
content: This chip is my first PIC bought from what seems like a NOS sweepsale. No eval kit found available elsewhere, I designed this, fitting PIC16F72 to Arduino form factor and interface. SPI and I2C are all wired Uno-style with the L13 LED.Since this PIC is so small that it does not even have an UART, no USB USRT interface is included, but interruptable GPIO is wired to pins 0 and 1 to allow easier implementation of software UART using interrupts.

author: Ian.M
author_rank: Super Contributor
timestamp: April 30, 2015, 02:37:34 pm
content: Use a six pin 0.1" pitch right angle header with the PICkit 2/3 pinout for the ICSP connections.The advantages of pin interrupts for a software UART are vastly overrated. If you need to do full duplex comms its better to poll the pin from a timer interrupt at an integer multiple of the baud rate (minimum x2), which lets you use the same interrupt to run state machines for both transmission and simultaneous reception. If you go down this route, its worth following the pinout of the PIC16F886 (TX on RC6, RX on RC7) so you can easily upgrade to a debug capable PIC wuth a hardware UART later when you find the PIC16F72 is too restrictive or frustrating.

author: tszaboo
author_rank: Super Contributor
timestamp: April 30, 2015, 03:05:26 pm
content: I dont know any valid reason why would anyone use a PIC16F72 for any new project. Unless you have a millions of it already and you need a programmable and gate.

author: technix
author_rank: Super Contributor
timestamp: April 30, 2015, 05:37:04 pm
content: Quote from: Ian.M on April 30, 2015, 02:37:34 pmIt got a little bit challenging for me to put the ICSP headers to the edge of the board so I decided to put it in the middle of the board and face up. Maybe will hamper debugging but at least works.

author: technix
author_rank: Super Contributor
timestamp: April 30, 2015, 05:38:47 pm
content: Quote from: NANDBlog on April 30, 2015, 03:05:26 pmMaybe that is why the seller is blowing off their stock of PIC16F72's at this ridiculous price (US$.25/each) and I got a lot of them.

author: Ian.M
author_rank: Super Contributor
timestamp: April 30, 2015, 06:07:23 pm
content: Buying them was a false economy.Comparewith PIC16F1512 which is as cheap as a dollar in quantity. It doesn't need an external crystal for most applications, has far better peripherals, much lower power consumption and is debug capable.However you have got them and they are slightly simpler to use than more modern midrange PICs so you might as well get your feet wet with them.
EZ-BLE PRoC: 10x10x1.8mm certified, qualified BLE module w/ ARM CM0 + CapSense - Page 1
Forum section: electronics / general

author: CypressPSoC
author_rank: Contributor
timestamp: April 30, 2015, 04:18:38 am
content: A few months ago, we announced PSoC 4 BLE and PRoC BLE - one-chip Bluetooth Smart solutions for the IoT.https://www.eevblog.com/forum/microcontrollers/psoc-4-ble-one-chip-solution-for-the-iot/We've now taken the PRoC BLE devices and packaged them into a small, 10x10x1.8mm, BLE-qualified, RF-certified module that includes an onboard chip antenna and all other passives - making the module very easy-to-use and helping take your designs to production quickly!Learn more here:www.cypress.com/BLEThe EZ-BLE PRoC module features:- ARM Cortex-M0 CPU @ 40MHz- 128KB Flash / 16KB SRAM (BLE Stack occupies ~64KB Flash)- Bluetooth 4.1 radio with integrated Balun and on-board chip antenna- CapSense touch-sensing on all IOs- 2 x UART/I2C/SPI- 1 x I2S (digital audio)- 16 x GPIO (all CapSense capable)- On-board crystals- 1.9 - 5.5 V operation- Industrial Temp -40C to +85C

author: miguelvp
author_rank: Super Contributor
timestamp: April 30, 2015, 04:26:41 am
content: Price? at least a ball park?BTW, still waiting for the PRoC mouse dev kit to be available

author: Corporate666
author_rank: Unknown
timestamp: April 30, 2015, 05:36:42 am
content: Can you give a *realistic* availability? I desperately want to use these in some new designs but I couldn't get any in time. I ended up buying a bunch of the CY8CKIT-042 BLE kits just to get the CY8CKIT-142 PSoC-BLE modules... only to find out the modules are now available for $10/eahttp://www.cypress.com/?rid=109296I have a trade show coming in a couple of weeks and I can get by with the -142 modules for demo purposes, but I hope to know when these modules will be available since they're the ones I want to implement

author: miguelvp
author_rank: Super Contributor
timestamp: April 30, 2015, 05:49:40 am
content: I have $25 for my contribution on the forums, I was going to use it for the PRoC mouse dev kit but I guess those CY8CKIT-142 combined with the prototype PSoC5 kits to use as the programmer might make me want to just get one of those and one of the CY5670 BLE-USB debugger to play aroundhttp://www.cypress.com/?rid=109298

author: miguelvp
author_rank: Super Contributor
timestamp: April 30, 2015, 06:25:05 am
content: I already have some PSoC5 prototype boards, but you are right, makes more sense to get the $49 kit, I guess I'll sleep on it. But I really want that PRoC mouse with the included miniprog 3
How to control a vintage 16x2 VFD? - Page 1
Forum section: electronics / general

author: singlarrysong
author_rank: Contributor
timestamp: April 29, 2015, 03:32:45 pm
content: I just bought a VFD from eBay, and i cant actually control it.I had follow the datasheet provide by the seller, however im still did not manage to control it. I tried to pop the data to a LCD control code(as standard ASCII) and it still nothing happen.here is my code--------------------------------------------------------------------------------#include <htc.h>#include <pic.h>__CONFIG (0x0FAC);__CONFIG (0x1CFF);#define _XTAL_FREQ 16000000 //for __delay_ purposevoid main(void){OSCCON = 0b01111010; //16MHz Fosc, Int Osc moduleTRISA = 0b00000001;ANSA0 = 0;TRISB = 0xFF; //data usesPORTA = 0b00000010;__delay_ms(1);PORTB = 0x0F; //show cursor__delay_us(1);RA1 = 1; //enable write__delay_us(300);RA1 = 0;__delay_ms(1);PORTB = 0x7F;RA1 = 1;__delay_us(300);RA1 = 0;for(;{}}-----------------------------------------------------------------------after fail on standard LCD control program, i decide to give a try on the cursor and full print to the screen, however it is again failhere is the datasheet and eBay link for the itemhttp://www.jdosher.pwp.blueyonder.co.uk/16x2vfd_7_IEE-03601-16x2-datasheet.pdfhttp://www.ebay.co.uk/itm/16x2-Vacuum-Flourescent-Display-5-volt-with-data-5x7-dot-matrix-8-bit-parallel-/381216029301?pt=LH_DefaultDomain_3&hash=item58c23efa75

author: Andy Watson
author_rank: Super Contributor
timestamp: April 29, 2015, 04:05:48 pm
content: Quote from: singlarrysong on April 29, 2015, 03:32:45 pmYou appear to have set PORT B as an input - and it remains so throughout the rest of the program. Controlling the VFD appears to be as simple as squirting ascii codes at it. Cursor positioning is done by "escape sequences".

author: jeroen74
author_rank: Frequent Contributor
timestamp: April 29, 2015, 07:12:35 pm
content: TRISx:1=(I)nput 0=(O)utput

author: singlarrysong
author_rank: Contributor
timestamp: April 29, 2015, 07:17:15 pm
content: Yea i saw that. A careless mistakeI'll give a reply if successnow had showing something

author: singlarrysong
author_rank: Contributor
timestamp: April 29, 2015, 07:53:20 pm
content: Success finally. But was limited to this code#include <htc.h>#include <pic.h>__CONFIG (0x0FAC); //see "Config" > "Configuration bits" for detail__CONFIG (0x1CFF); //as above#define _XTAL_FREQ 16000000 //for __delay_ purposevoid main(void){OSCCON = 0b01111010; //16MHz Fosc, Int Osc moduleTRISA = 0x00;PORTA = 0;TRISB = 0x00;__delay_ms(1000);PORTB = 0x7F;RA0 = 1;__delay_us(250);PORTB = 0;RA0 = 0;for(;{}}
Using an ESP8266 to add Wifi to an FPGA project - Page 1
Forum section: electronics / general

author: hamster_nz
author_rank: Super Contributor
timestamp: April 23, 2015, 10:47:20 am
content: Hi!I've been playing with the low cost ESP8266 modules, that present a IP-over-WiFi as a serial device, and you use modem-like AT commands to control it.I've just put up a project that allows the FPGA to connect to my Wifi network, then send status message to a service that is listening on my Linux VM. It is all done using VHDL state machines (no software CPU), and could most probably be made a little more compact. Oh, and I know nothing about VHDLs string handlingBecause the serial port is running at 9600 and the AT command based protocol overhead it is a pretty low bandwidth solution, but enough if you wanted to add some basic WiFi telemetry to an FPGA design without using and embedded software stack.The ESP8266 module used was under $7 -http://www.seeedstudio.com/depot/WiFi-Serial-Transceiver-Module-w-ESP8266-p-1994.htmlYou can find all the source on my Wiki athttp://hamsterworks.co.nz/mediawiki/index.php/FPGA_ESP8266

author: bingo600
author_rank: Super Contributor
timestamp: April 24, 2015, 02:51:43 pm
content: Nice workIs UCF files not used on a basys3 ?/Bingo

author: Korken
author_rank: Regular Contributor
timestamp: April 26, 2015, 05:41:16 pm
content: XDC is the new format used by Vivado which is replacing UCF files.Hope is helps!
Arduino Due, how to direct stdio to USART0 or USART1 - Page 1
Forum section: electronics / general

author: riscy00
author_rank: Contributor
timestamp: April 25, 2015, 07:09:27 am
content: HiArduino Due with SAM3X (Cortex M3), I could not find material that advise how to configure commands from STDIO.h to redirect serial message stream to specfic port, for example printf("Hello World!\n) to USART0 or USART1.....

author: westfw
author_rank: Super Contributor
timestamp: April 25, 2015, 08:00:19 am
content: I believe that Due uses newlib, so the following should work. (I haven't actually tried it on a Due (I don't have one), but it works for Energia Stellaris platforms. See this thread:http://forum.43oh.com/topic/8308-yet-again-another-boring-question-about-energia-printf/)Code:ssize_t myWrite(void *cookie, const char *buf, size_t n){return Serial.write((uint8_t*)buf, n);}cookie_io_functions_t myVectors = { 0, myWrite, 0, 0 };void setup() {Serial.begin(115200);stdout = fopencookie((void *)0, "w", myVectors);setlinebuf(stdout);printf( "This is an fprintf demo\n");}This sucks in the well-known large-ish printf(), and it also sucks in newlib's whole stdio/file/etc implementation, adding a total of about 20k to your sketch binary size. And it may have weird buffering issues and need an occasional fflush(stdout) call.
CH340 programmer problem - Page 1
Forum section: electronics / general

author: djluck
author_rank: Newbie
timestamp: April 23, 2015, 04:43:59 pm
content: Hi!I have a usb to serial converter based on a CH340G chip. Yesterday I used it to program an atmega 328p without any problems. Today, when I wanted to reprogram the chip, it gives me the following error:avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x01avrdude: stk500_recv(): programmer is not respondingavrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x01Problem uploading to board.I have tried every thing that I could think of. Restarted the computer, tried it on another computer, tried to program another chip, tried to reinstall the drivers.I am running windows7 x64. And yes, I am able to see the device listed in device manager. I made sure that the port, board and processor are the correct ones selected.Can somebody help me with this problem ?Thanks in advance.
Help me about 8x8 Matrix led - Page 1
Forum section: electronics / general

author: Nhan95
author_rank: Contributor
timestamp: April 21, 2015, 07:12:35 am
content: I buy an one color 8x8 matrix led. But It has 24pins !! I think it ought to have only 16 pins. So I'm confused how to use it. Could you help me ?

author: Thor-Arne
author_rank: Unknown
timestamp: April 21, 2015, 08:45:57 am
content: First, we need to see the datasheet.Post the brand and part number.I expect this to be a dual-color matrix.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: April 21, 2015, 08:56:53 am
content: Probably dual colour, though you sometimes get single colour ones in a dual-colour package where they have only populated one set of colour die.

author: JoeN
author_rank: Frequent Contributor
timestamp: April 21, 2015, 07:03:05 pm
content: On most devices I would say you need a datasheet too, but not for an LED matrix, at least not for hobby purposes. If your intent is to build commercial devices, you need the datasheet, though. This is just for playing around with. LEDs are the easiest things to "buzz out" in the world. The way I do it is send 5V to my breadboard, put a sane resistor like 330 ohm between 5V and another point, add a long test lead to that point, a long test lead to ground, plug the matrix in, and just try random connections until I get a segment to light up. Under these conditions, that is safe. Once you find a connection through an LED note your lead positions then move the ground lead to find another good position. If the row moves then it is row common cathode and if the column moves then it is column common cathode. Either way, check all positions with the GND lead to find all of the columns or rows and then repeat with the VCC lead to find the other.Like this, which only took me a few minutes to do:
modding an ESP-01 module for breadboard use - Page 1
Forum section: electronics / general

author: ralphd
author_rank: Frequent Contributor
timestamp: April 20, 2015, 03:13:03 pm
content: No parts required, just a soldering iron, and optionally a pair of pliars.http://nerdralph.blogspot.ca/2015/04/adapting-esp-01-module-for-breadboard.html
STM32 Access SD Card Through USB? - Page 1
Forum section: electronics / general

author: stoic
author_rank: Newbie
timestamp: April 16, 2015, 05:40:56 am
content: After some head scratching, I've finally managed to communicate with an SD Card using STM32F407 (STM32F4 Discovery board). I used the Fat FS library along with some SDIO example code to get this up and running with CooCox.Since the microcontroller supports USB, I thought it would be interesting if it could enumerate as mass storage device and be able to access contents of the SD card. This would open up possibility of setting configuration parameters by dragging / dropping raw text files without any driver installs or custom software.I'm still trying to get the hang of USB stuff, was wondering if something like this is overly complex to implement?Thanks!-S

author: miceuz
author_rank: Frequent Contributor
timestamp: April 16, 2015, 05:14:15 pm
content: Not at all - all you have to do is configure the usb properly (not trivial unfortunately) and implent some scsi hooks where you pass data to and from sdcard. I've seen an mbed example where mass device was using eeprom as storage, google around.

author: zapta
author_rank: Super Contributor
timestamp: April 16, 2015, 05:19:14 pm
content: Mbed had good USB support. Search for us device, it has several USB device types.(And you don't have to use the online IDE, you can export the project to your machine)
Reading frequency from TSL235R LIGHT-TO-FREQUENCY using a TIVA TM4C123 LaunchPad - Page 1
Forum section: electronics / general

author: chintanp
author_rank: Newbie
timestamp: April 15, 2015, 10:27:26 am
content: I have a TSL235 R light to frequency converter, the datasheet is here:http://www.rhydolabz.com/documents/sensors/TSL235R_LF.pdf.I want to measure the output frequency which is in the range of 250 kHz. I have an ARDUINO Uno and TIVA LaunchPad. How can I interface the sensor with the board for the frequency measurement ?I am not an electronics engineer, so only reading the datasheet doesnt do it for me.Page 5 of the datasheet shows the diagram to interface the sensor with an MCU. Is it possible to do with TIVA Launchpad ? Will it be accurate enough ? Any example program for this implementation ?- RegardsChintan PathakAsst. Prof,CED, IES, IPSA.

author: rs20
author_rank: Super Contributor
timestamp: April 15, 2015, 10:54:18 am
content: This is well within the capabilities of an Arduino, example:http://interface.khm.de/index.php/lab/interfaces-advanced/arduino-frequency-counter-library/Ignore the fancy circuitry shown on that page, that's to deal with weak signals. Because you have a strong signal from your light measurement device, you can interface directly as suggested by your document. To pin 5 of the arduino.
ESP8266 - I2C EEPROM Data Logger - AT24C32/64 Driver - Page 1
Forum section: electronics / general

author: TJ232
author_rank: Frequent Contributor
timestamp: April 14, 2015, 07:47:13 am
content: As you might remember from our previous article about DS3231 RTC Module -http://www.esp8266-projects.com/2015/04/mailbag-arrival-ds3231-i2c-real-time.html, we have identified onboard an EEPROM chip, a 32k AT24C32 one. It is independent from the RTC circuit and conected on the I2C bus, a perfect companion for a Data Logger SystemFor more details about:http://www.esp8266-projects.com/2015/04/at24c32-i2c-external-eeprom-data-looger.html

author: senso
author_rank: Frequent Contributor
timestamp: April 14, 2015, 08:33:42 pm
content: Isn't that were the ESP loads the code from?

author: TJ232
author_rank: Frequent Contributor
timestamp: April 15, 2015, 04:01:20 am
content: Quote from: senso on April 14, 2015, 08:33:42 pmI'm sorry but don't understand the question. Please refine.
ESP8266 - DS3231 - Real Time Clock Module - I2C Driver   - Page 1
Forum section: electronics / general

author: TJ232
author_rank: Frequent Contributor
timestamp: April 09, 2015, 06:36:30 am
content: If you remember my article about PCF8563 Real Time Clockhttp://www.esp8266-projects.com/2015/03/pcf8563-real-time-clock-i2c-driver.htmlthis one was a looong avaited item. Actually I didn't expect it to show anymore after so much time but miracles happening sometimeThe DS3231 is a extremely accurate I2C real-time clock (RTC) with an integrated temperature-compensated crystal oscillator (TCXO) and crystal. The device incorporates a battery input, and maintains accurate timekeeping when main power to the device is interrupted.For more details:http://www.esp8266-projects.com/2015/04/mailbag-arrival-ds3231-i2c-real-time.htmlVideo :

author: DavidDLC
author_rank: Frequent Contributor
timestamp: April 09, 2015, 07:08:06 am
content: What a coincidence, I'm just playing with the PCF8563 and waiting on the mail for my DS3231, I'm validating both for a perfume sprayer project I'm working on.Basically this perfume sprayer will start working at 5:00 pm right before I arrive from work and will stop spraying at midnight when I go to bed from Monday to Friday and Saturday and Sunday will have a time frame to spray the perfume as well.Nice work with your webpage.David.

author: TJ232
author_rank: Frequent Contributor
timestamp: April 09, 2015, 07:31:32 am
content: Quote from: DavidDLC on April 09, 2015, 07:08:06 amThank you for your kind words. You have also a nice project out thereI will suggest you to use PCF8563, much cheaper and easier to implement. I have used it in many projects without any problems. It will make no difference for your hi-tech spray. I will be more than happy to see some pictures/details of your project.I hope you are aware of the danger of continuous usage of house perfume/air fresheners as they can trigger asthma and morehttp://www.nyrnaturalnews.com/health/2011/11/doctors-say-air-fresheners-can-trigger-asthma-and-more/
microcontroller board  - Page 1
Forum section: electronics / general

author: a.soliman
author_rank: Newbie
timestamp: April 06, 2015, 07:45:10 am
content: Hello all,I want to ask about the proper hardware design for a microcontroller board... tips and tricks for the power rails, input and output protection and anything that I should be aware of to ensure the operation stabilityThanks in advance

author: Ian.M
author_rank: Super Contributor
timestamp: April 06, 2015, 08:46:30 am
content: That is incredibly dependent on the microcontroller family chosen. Many have special requirements.However there are a few common factors:* Ground plane - don't try to do without it if there are external signals with less than 1us between edges. You may be able to get it to work with faster signals without one but its not good practice.* Connect *ALL* supply and ground pins unless the datasheet says otherwise - internal power bus metalisation between different sections of the chip is often not sized to carry the full rated supply current.* Decouple *ALL* Vdd supply pins as close to the pin as possible.* Keep supply tracks short and wide - don't snake one round the board edge to avoid a wire link or a few vias.* Keep any external crystal connections close to the chip and clear of other signals.For the rest, if there is a manufacturer's demo board or reference design, STUDY IT, otherwise study the datasheet till you can quote it in your sleep!

author: poorchava
author_rank: Super Contributor
timestamp: April 06, 2015, 08:53:49 am
content: Unless your uC has internal slew rate limiting, you may want to connect a small resistor (47-100R would be a good start) in series with every output pin. This will decrease the amount of ringing and also protect the uC a little bit in case of short circuit.Make sure that traces from crystal to the uC are as short as possible, preferably far from other signal traces.Make sure to include at least one larger cap somewhere nearby the uC for bulk filtering.Make sure that the reset pin is treated exactly as outlined in the datasheet. Use weak pull-up in case the uC doesn't have one internally (100k would be good start)

author: a.soliman
author_rank: Newbie
timestamp: April 08, 2015, 11:25:27 am
content: Thank you guys
avrdude: Device signature = 0x000000 - Page 1
Forum section: electronics / general

author: mushroom
author_rank: Regular Contributor
timestamp: April 14, 2015, 12:10:25 am
content: Hello,I tried to burn the bootloader into a (ab)used Arduino Pro Mini 5V 16MHz clone. In order to be able to do this on a board possibly comming without a bootloader. This Arduino clone has a fried ADC, but still works. It can run sketches.I used and connected (properly) a genuine Mega as ISP programmer.After following the different steps (ISP programmer sketch to Arduino Mega, then bootloader with Arduino as a programmer), I get the message :avrdude: Device signature = 0x000000I did'nt try the -F parameter, but I verified the external oscillator, and it works : 16MHz (I read it could be a dead xtal...) a lab PSU was used for both Arduino (I'm aware of problems resulting from connecting one to the other's regulator)The main question is not "how to fix this ?" (in fact there's nothing to fix, as the Pro Mini works, except the dead ADC !), but rather "what does this mean ?".Could some fuse bits have been changed when I fried the ADC ? For example, the clock settings changed from externel to internal ? I also read on eevblog that a 0x000000 signature could be set by board manufacturer in order to pevent user from reprogramming the bootloader.Any information ?

author: mushroom
author_rank: Regular Contributor
timestamp: April 16, 2015, 12:37:01 am
content: In fact, it was a stupid mistake : the Pro Mini under test (to be flashed with bootloader) was powered with the lab PSU (seems to be a prerequisite : ok) to the "RAW" pin (regulator input), insteed of Vcc !!!Just a trivial wiring mistake.

author: c4757p
author_rank: Super Contributor
timestamp: April 16, 2015, 12:40:55 am
content: Yup, "Device signature = 0x000000" is pretty much always a wiring fault. It's the equivalent of "TDO stuck at 0" in a JTAG system.
ESP8266 - 18 Bit ADC - MCP3421 - I2C Driver - Page 1
Forum section: electronics / general

author: TJ232
author_rank: Frequent Contributor
timestamp: April 06, 2015, 07:39:03 am
content: After testing the ESP8266 Internal ADC -http://www.esp8266-projects.com/2015/03/internal-adc-esp8266.htmllet's see also a higher resolution ADC at work.The MCP3421 is a single channel, low-noise, high accuracy delta-sigma A/D converter with differential inputs and up to 18 bits of resolution in a small SOT-23-6 package. The on-board precision 2.048V reference voltage enables an input range of ±2.048V differentially.The device uses a two-wire I2C compatible serial interface and operates from a single power supply ranging from 2.7V to 5.5V, has a decent price and looks like a good companion for our ESP8266 module.For more details :http://www.esp8266-projects.com/2015/04/18-bit-adc-mcp3421-i2c-driver-esp8266.htmlVideos:1. Test done in filtered environment - stable voltage2. Test done in noisy environment - using real bus unfiltered ?voltage3. Test done in noisy environment - values are printed directly on CBDB DevBoard LCD Display?

author: Muxr
author_rank: Super Contributor
timestamp: April 07, 2015, 02:51:52 am
content: Relatively cheap too. Nice!
zero-wire auto-reset for esp8266/Arduino - Page 1
Forum section: electronics / general

author: ralphd
author_rank: Frequent Contributor
timestamp: April 06, 2015, 10:22:08 pm
content: Adding a capacitor and resistor simplifies uploading and improves stability of esp8266 modules.http://nerdralph.blogspot.ca/2015/04/zero-wire-auto-reset-for-esp8266arduino.html
ESP8266 - LM75 I2C temperature sensor - LCD display  - Page 1
Forum section: electronics / general

author: TJ232
author_rank: Frequent Contributor
timestamp: April 03, 2015, 11:37:06 am
content: I was asked if MCP9008 Temperature sensor can be replaced with the cheaper and widely available LM75 one.The answer is YES, it can be done without any problems, actually they can share same slot on CBDB Dev Board without any hardware changes as pin compatible, just choose your desired I2C address with the A0, A1, A2 pins.More details :http://www.esp8266-projects.com/2015/04/lm75-i2c-temperature-sensor-driver-cbdb.htmlVideo:
April Fool’s Project! - Page 1
Forum section: electronics / general

author: @rt
author_rank: Super Contributor
timestamp: April 02, 2015, 12:14:29 am
content: Hi Guys,I wrote a pic program that can tell what oscillator frequency is clocking it.Best quality video I could do to get it out for April Fools’ Day (UTC).Cheers, Art.

author: Ian.M
author_rank: Super Contributor
timestamp: April 02, 2015, 12:31:51 am
content: I assume you are using the internal WDT timer timeout to determine the clock speed.Start Timer 1 on powerup, Wait for a WDT reset.If it was a WDT reset skip the above, read timer 1 to get the speed then, knowing that your clock speeds are separated by more that the 40% WDT clock error simply pick the closest known speed to calibrate your delays which must keep 'kicking the dog' with the CLRWDT instruction.

author: @rt
author_rank: Super Contributor
timestamp: April 02, 2015, 12:45:12 am
content: Wow this paid offYour way might be better than mine.BUT is the timer1 value not reset with he WDT so you could not read the timer values after reset?

author: Ian.M
author_rank: Super Contributor
timestamp: April 02, 2015, 01:11:34 am
content: No. see datasheet DS40044G section 7.6

author: @rt
author_rank: Super Contributor
timestamp: April 02, 2015, 01:28:13 am
content: Ok, I’m busted. I was a lot more sloppy, you will not like itMake a fixed delay that will vary with clock speed,run that delay in a loop that also writes a zero byte to on-chip EEPROM and increments the address,The watchdog resets before it can fill the 256 bytes of EEPROM.Then after reset count the number of zero values on the EEPROM,write all 0xFF values to EEPROM for the next startup and go from there.I appreciate your input.I want to add a toggle flip flop to this for a few more frequencies and use the code in a bigger project.