hybridfree/eevblog-posts huggingface dataset:
GigaDevice -- opinions - Page 1
Forum section: electronics / general

author: blueskull
author_rank: Unknown
timestamp: January 30, 2019, 06:59:47 am
content: I'm looking for a super tiny flash chip with DIO SPI to boot my DSP.With extreme space constraint, I'm left with 1.5mm*1.5mm DFN and 1.6mm*1.6mm BGA.The latter is from Aldesto, a well known brand, but the BGA is pretty nasty to handle. The pitch is very small, and I'm only comfortable down to 0.5mm pitch.The former is from a less know brand, better known for its STM32 clone.My question is, have any of you used GD flash chips, and what's their quality.I know their dies are used in ESP32 SiP modules, and I have no complaints about them.But for their lower end 1Mbit chips in such a crazy small package -- any ideas?FYI:https://www.digikey.com/product-detail/en/gigadevice-semiconductor-hk-limited/GD25D10CKIGR/1970-1086-1-ND/9598060

author: lucazader
author_rank: Regular Contributor
timestamp: January 30, 2019, 06:16:45 pm
content: I have used them in production products before.No complaints so far, much cheaper than the winbond chips we were using and no noticeably higher defect rate etc.Although we dont do too many write/erase cycles, so cant attest to the lifespan of the flash if that's what you are after.
SOLVED (ish): layout goof: Can I use 3.3V instead of 2.5V for MAX10 LVDS inputs? - Page 1
Forum section: electronics / general

author: aandrew
author_rank: Frequent Contributor
timestamp: January 28, 2019, 11:32:50 pm
content: This is one of those dumb mistakes that made it through review.Altera MAX10M08DAF, I have a number of LVDS inputs on banks 5 and 6. I connected the VCCIO for these banks to 3.3V and not 2.5V as is specified in the manual.This is a BGA device and it's going to be a royal PITA to repair this, but I'm literally a day or two out from the parts being populated on the errored boards so if it needs to be fixed, this is the best time to do it.My question is how bad of a screwup is this? The LVDS signals are all inputs to the FPGA, and the maximum clock frequency will be 125MHz, and some of those LVDS signals are DDR, so the bit rate on some of those LVDS signals will be 250Mbps.Will I get a "hail mary" pass by virtue of this being a receive-only interface, or should I bite the bullet, halt assembly of these prototypes and try to rework the 7 balls (buried inside the array of course) so they receive 2.5V?

author: langwadt
author_rank: Super Contributor
timestamp: January 29, 2019, 12:08:04 am
content: Quote from: aandrew on January 28, 2019, 11:32:50 pmit will most likely work just fine LVDS receivers are really just comparators, I've seen Xilinx say that it will workwith the exception if you use the buildin termination it might not be quite the right valueoutput is worse, on Zynq the LVDS output turn off when the bank voltage is above ~2.9V to protect the transistors, aprrently they can't have the same voltage as the ones for CMOS

author: asmi
author_rank: Super Contributor
timestamp: January 29, 2019, 12:39:08 am
content: On Xilinx's 7 series VCCIO doesn't matter if you want to use LVDS inputs and no onchip termination. So check the datasheet for your FPGA to see if it's the same. If you did plan to use onchip termination, you can opt not to and fit 100 Ohm 0402 or 0201 resistor (size depends on the pitch of your FPGA) under BGA across breakout vias. At 250 Mbps you should be OK.If 2.5 V is a requirement for your FPGA, I wouldn't even bother assembling the board and would do a respin right away, as I doubt there is a good way you can rework VCCIO balls because generally they are connected directly to the power plane and there is likely no way to sever that connection.

author: aandrew
author_rank: Frequent Contributor
timestamp: January 30, 2019, 02:51:57 am
content: Hey everyone. Just an update.I have successfully used the 10MHz and 125MHz clocks coming in on some of these LVDS signals to drive the PLL and get basic blinky logic working. At least at first glance it looks like I may have succeeded despite the wrong I/O voltage on these banks with LVDS. Further testing will tell if I can hit 250Mbps on the DDR data, but for now it looks like I'm still hanging on. :-)
Cheap 75V buck Ideas - Page 1
Forum section: electronics / general

author: ali_asadzadeh
author_rank: Super Contributor
timestamp: February 04, 2019, 11:38:06 am
content: Hi,I want to design a simple 75V input 5V 500ma output Buck converter, I needs to be super cheap!Do you have any part or idea in mind? I was considering UC3843 as a flyback, but I wanted to know if we have something even cheaper

author: mariush
author_rank: Super Contributor
timestamp: February 04, 2019, 12:13:50 pm
content: Richtek RT6210?https://www.richtek.com/assets/product_file/RT6210/DS6210-00.pdf2.6$ in 10pcs ... though kinda inefficient, around 70% eff. at 70v in , 5v out...Seems expensive but keep in mind you don't need transformer with custom windings, additional mosfet, extra parts around it etc...There's alsoMAX5033but its maximum voltage is 76v... you'll definitely have to be careful and ideally drop the voltage by a few volts :https://datasheets.maximintegrated.com/en/ds/MAX5033.pdfIt would probably be expensive if you buy low quantities and... it's Maxim, you may have problems buying them at some points.If you can get your maximum voltage below 50v, you could use cheaper regulators, like let's say a 1.3$ MCP16331 :http://ww1.microchip.com/downloads/en/DeviceDoc/20005308C.pdfYou could do that with a bunch of diodes in series, or if your input voltage is always within some high range, maybe using a dropper resistor.1n4149 diodes are cheap, 3-5 cents each if you buy 100, and each drops 1v...

author: mvs
author_rank: Frequent Contributor
timestamp: February 04, 2019, 03:20:01 pm
content: Quote from: ali_asadzadeh on February 04, 2019, 11:38:06 amCheaper then UC384x? Some chinese flyback controllers with integrated switch can cost less then $0.05/pcs in volume. But you will need flyback transformer in both cases...https://lcsc.com/product-detail/Others_Shenzhen-Chip-Hope-Micro-Electronics-LP3668B_C360134.htmlhttps://lcsc.com/product-detail/Power-Management-Specialized-PMIC_Shenzhen-Chip-Hope-Micro-Electronics-LP3773A_C125952.htmlSome buck converters, like XL7036, can be cheaper in total costs, but are less safe to use and dissipate more power.http://www.xlsemi.com/datasheet/XL7036%20datasheet-English.pdfhttps://lcsc.com/product-detail/DC-DC-Converters_XL7036_C89530.html

author: SiliconWizard
author_rank: Super Contributor
timestamp: February 04, 2019, 04:06:50 pm
content: Unless you absolutely need isolation, I wouldn't go for a flyback design. You'll need a handful of components including a transformer that can be costly (unless you're targetting very high quantities), and designing a robust flyback converter is not as easy as it sounds. If this is a learning exercise, then why not, you'll certainly learn a few things, but expect to be burning a few transistors before getting it right. And I'm not talking about EMI...There are high voltage buck converters, mariush gave you some references, you can also find some from LT/AD (for instance, the LTC3894, but there are a few others in the same ballpark depending on the output current you need).Just my 2 cents.
STM8: Timer2 channel compare output pin, setting initial value, then toggle - Page 1
Forum section: electronics / general

author: rhodges
author_rank: Frequent Contributor
timestamp: January 26, 2019, 10:48:26 pm
content: I am planning to use an STM8 Timer2 channel as an output. Here is the basic idea:1. Wait some period of time.2. Set the channel output pin high.3. Read the timer count, add 400, and write to the compare register.4. When the count and compare match (400 ticks) later, the output pin toggles automatically.5. Catch the interrupt and set a new compare value.Bits OC1M in TIM2_CCMR1 set the behavior of the output pin.Using 101 is "Force active level - OC1REF is forced high". That takes care of (2) above.But I want to use 011 "Toggle - OC1REF toggles when TIM2_CNT = TIM2_CCR1" so that the pin will toggle automatically.My datasheet "DocID14587 Rev 14" does not seem to address this.Will this work?1. Set OC1M in TIM2_CCMR1 to 101 to set the output pin to high. Then, immediately after:2. Set OC1M in TIM2_CCMR1 to 011 to toggle the pin (to low) when the count matches (400 ticks later).To ask this a different way, when I write 011 for "toggle", does it leave the current pin value unchanged? (Until the count and compare match.)I am suspicious about *assuming* any behavior that is not well documented.For the curious, this is serial bit-banging and I would like the timer channel to handle the pin timing, and avoid jitter from interrupt latency.Thanks!

author: rhodges
author_rank: Frequent Contributor
timestamp: January 27, 2019, 06:24:20 pm
content: Update:The timers and capture/compare channels appear to be very close between STM8 and STM32. So I looked at RM0360 for STM32F030 to see if there is anything useful there. I did not find anything new about OC1REF. But there was a code sample (A.8.7) for setting up a channel for output compare with toggle. This code did not do anything to clear OC1REF before setting the 011 bits for toggle.I went back to the STM8 manual, looking for every reference to OC1REF. There is no mention about clearing it before using toggle mode (say, from an unknown state.) The relevant timing diagrams appear to show that OC1REF just magically starts in the clear state.Sigh. I would really like to look at the logic inside the "Output Mode Controller" that creates OC1REF. I will keep looking.
Sensor to ADC - Page 1
Forum section: electronics / general

author: nForce
author_rank: Frequent Contributor
timestamp: January 26, 2019, 04:24:44 pm
content: We have a sensor which measures pressure it's rated between 200 mbar and 2000 mbar. The output of a sensor is between 0 V and 3 V. We connect the sensor's output to the input of an ADC which is 10-bit and it's rated between 0 V and 3 V. How would we convert the pressure into a number which we get in the ADCRESULT register?

author: palpurul
author_rank: Regular Contributor
timestamp: January 26, 2019, 04:46:11 pm
content: I think you should check the datasheet of the sensor you're using. There should be some sort of look up table or equation mapping pressure to voltage output.

author: nForce
author_rank: Frequent Contributor
timestamp: January 26, 2019, 05:19:47 pm
content: I am not using any sensor, this is an only theoretical task.Just explain how would I achieve the conversion thing.

author: james_s
author_rank: Super Contributor
timestamp: January 26, 2019, 06:56:09 pm
content: If the output is linear, you'd just scale the value into whatever units you want. Otherwise you'd generally use a lookup table.

author: nForce
author_rank: Frequent Contributor
timestamp: January 26, 2019, 07:37:32 pm
content: Yes, it's linear. We don't use a lookup table.Can you solve and explain for this example?

author: palpurul
author_rank: Regular Contributor
timestamp: January 26, 2019, 07:38:50 pm
content: Let's say that an imaginary pressure sensor gives 0V output for 200mbar and 3V for 2000mbar. In that case ADC code for 200mbar would be 0x000 and for 2000mbar would give you the max. code (0x3FF). Assume that the sensor is linear then you can come with a linear equation using these two set of values.

author: nForce
author_rank: Frequent Contributor
timestamp: January 26, 2019, 09:57:45 pm
content: ThanksI have solved by using units. Can anyone look at this if it's correct? I am not really a math person.(3V - 0 V)/(2000 mbar - 200 mbar) = 1/600 V/mbarAnd...(2000 mbar - 200 mbar)/ (1024 - 0) = 225/128 mbar/bitSo by units: 1/600 V/mbar * 225/128 mbar/bit, the mbar cancels. And we get 3/1024 V/bit.

author: palpurul
author_rank: Regular Contributor
timestamp: January 27, 2019, 06:19:53 am
content: Quote from: nForce on January 26, 2019, 09:57:45 pmIt looks incorrect.Here is the correct equation for mbar/V:600*V+200 (checking it real quick: for 0V it gives you 200mbar for 3V it gives you 2000mbar)Converting that to mbar/bits:(600*(3/1024))*ADC_code+200 (again for 0 it gives you 200mbar and for 1024 it gives you 2000mbar)I basically construct a linear line with known points.It is explained here:here
Ultrasonic levitation - Page 1
Forum section: electronics / general

author: ebclr
author_rank: Super Contributor
timestamp: January 25, 2019, 04:32:50 am
content: https://www.youtube.com/watch?v=p1Vm4cL4aUA&feature=youtu.beWhat a nice project

author: FlyingDutch
author_rank: Regular Contributor
timestamp: January 25, 2019, 11:28:01 am
content: Hi,indeed coolRegards
MC9S08PL16 what if /RESET not used? - Page 1
Forum section: electronics / general

author: Circlotron
author_rank: Super Contributor
timestamp: January 24, 2019, 04:47:18 am
content: Looking to update several older boards that currently use a HC908 micro. Looking at a MC9S08PL16 that has a bit extra IO that might come in handy. Anyway, on the LQFP package version pin 31 is used for PTA5, IRQ or RESET. The code uses some BIL and BIH instructions and it's cycle sensitive so I'm not going to change it. Question - because it would be unavailable, what is the downside to not using the RESET?
St link utility with Nucleo F401RE - Page 1
Forum section: electronics / general

author: lorenrus
author_rank: Regular Contributor
timestamp: January 24, 2019, 05:38:06 pm
content: Hii have to modify the value of some registers to unable the ETM.i'm using st link utility. I can search the address of my register but when i modify it's value i have an error, view the image.Thank you very much

author: nsrmagazin
author_rank: Regular Contributor
timestamp: January 24, 2019, 06:33:23 pm
content: It seems like you do not have access to the memory. It might be damaged, the cable to be damaged or the programming device.

author: lorenrus
author_rank: Regular Contributor
timestamp: January 24, 2019, 07:12:39 pm
content: Hi and thanks for reply.hi tried to use another cable but the result is the same.What do you advise me to do ?Thank you very muchLorenzo

author: nsrmagazin
author_rank: Regular Contributor
timestamp: January 25, 2019, 08:54:31 am
content: Can you try to use another memory, another programmer or test the setup on another computer(virtual machine will also do) or check if the settings for this device are ok. Maybe its not getting VCC or ground on some pin that should be connected.

author: lorenrus
author_rank: Regular Contributor
timestamp: January 25, 2019, 09:31:37 am
content: Hii'm using only tha cable USB - USBMINI.When i linked my board i opened St Link i pushed the voice Target and after the voice Connect and the result is shown in the image.In the image tool st link told me that is connnected with my board but if you see the Underlined part .. NORMAL CONNECTION. Is correct this type of connection if i want to modify the value of registers ?Thank you very muchLorenzo

author: lorenrus
author_rank: Regular Contributor
timestamp: January 25, 2019, 03:12:17 pm
content: I have to activate the card ETM and I found that I can edit the register ETMCR.Thank youLorenzo
Op amp in MCU ? - Page 1
Forum section: electronics / general

author: Jan Audio
author_rank: Frequent Contributor
timestamp: January 19, 2019, 04:25:38 pm
content: What is the op amp in microcontrollers ?I have the PIC16F1704 :http://ww1.microchip.com/downloads/en/DeviceDoc/40001715D.pdfThis chip has also a DAC, wich i buffer in external opamp.I heard i can not use the op amp to buffer the DAC.What is the opamp for then ?

author: cv007
author_rank: Frequent Contributor
timestamp: January 19, 2019, 04:48:31 pm
content: QuoteThe datasheet says the op amp can select the dac_output for the non-inverting input. I would assume if the dac chapter does not mention the internal op amp, its because it was copy/pasted into the datasheet from some other device that has no internal op amp (most do not). You have the chip, so try it- either the op amp chapter is wrong and you cannot select dac_output as it claims, or it works as advertised.QuoteYou have the input/output pins available, so can do 'op amp things'. With 2 of them, you get twice the fun.

author: Jan Audio
author_rank: Frequent Contributor
timestamp: January 19, 2019, 05:16:01 pm
content: Thanks, will try, lets see if its as fast as the best/fastest opamp i have.

author: Flenser
author_rank: Regular Contributor
timestamp: January 20, 2019, 05:08:35 am
content: TABLE 32-17 in the datasheet lists the specs for the opamp

author: Jan Audio
author_rank: Frequent Contributor
timestamp: January 20, 2019, 05:55:42 pm
content: Ah, to bad its slower, the opamp i got has slew rate of 7, this one 3.

author: technix
author_rank: Super Contributor
timestamp: January 24, 2019, 07:50:46 am
content: Quote from: Jan Audio on January 20, 2019, 05:55:42 pmThere is no point using a faster opamp for a slow DAC though. And you can always use external wiring shorting some MCU pins together to chain the DAC to internal opamp.

author: Jan Audio
author_rank: Frequent Contributor
timestamp: January 24, 2019, 03:27:34 pm
content: Ok, i thought the DAC is as fast as the opamp ?
[atmega 0-series] 'TCA_t {aka union TCA_union}' has no member named 'INTCTRL' - Page 1
Forum section: electronics / general

author: Simon
author_rank: Unknown
timestamp: January 21, 2019, 07:12:49 pm
content: Code:'TCA_t {aka union TCA_union}' has no member named 'INTCTRL'this comes from invoking TCA0.INTCTRL which is totally valid as a variable/register name and there is a INTCTRL element to the structure TCA. All I can assume is that there is some sort of mess here with single and split operation as there are two structure setups one for each.

author: cv007
author_rank: Frequent Contributor
timestamp: January 21, 2019, 07:36:04 pm
content: Lookup TCA_t, INTCTRL is not there, you need to use SINGLE or SPLIT-TCA0.SINGLE.INTCTRLTCA0.SPLIT.INTCTRLcompiler is right and the error means exactly what is says

author: Simon
author_rank: Unknown
timestamp: January 21, 2019, 07:39:54 pm
content: I see
atmel studio [asf] and cpp - Page 1
Forum section: electronics / general

author: hsn93
author_rank: Regular Contributor
timestamp: January 17, 2019, 03:19:41 pm
content: hello,i want to make c++ project in atmel studio and get use of ASF.if you add asf from asf wizards the project does not build and it seems like the files inCode:src\ASF\sam\utils\cmsis\sam4e\include\componentare not getting included!!although i can see them in the and they are included by you sam series file.hmost likely the errors are in the files ofCode:src\ASF\sam\drivers---I've seen many people say that they make their own drivers but then isn't that time consuming?i mean i know that i cant make my own driver i can copy files from asf but (one by one its so much time consuming).so for people who program with asf. do you always use C only?or you use .o files that are compiled by c? "if so, how do you achieve that?"
[atmega 0-series] random missing '(' and ')' error - Page 1
Forum section: electronics / general

author: Simon
author_rank: Unknown
timestamp: January 17, 2019, 03:50:33 pm
content: Code:#include <inttypes.h>#include <avr/io.h>PORTF.DIRCLR = 0x01 << 0; // set PF0 to inputCode:Errorexpected identifier or '(' before 'PORT_t'Errorexpected ')' before numeric constantI am confused, I have used similar code in another project with no issue. Apparently these parenthesis need to go before PORTF, both of them.

author: tsman
author_rank: Frequent Contributor
timestamp: January 17, 2019, 04:18:28 pm
content: Put it into a function. You can't initialise it like that.

author: Simon
author_rank: Unknown
timestamp: January 17, 2019, 04:23:13 pm
content: yea, duh of course, I'm a bit out of practice
CS4344 (24 bit DAC) - Page 1
Forum section: electronics / general

author: alizare368
author_rank: Regular Contributor
timestamp: January 17, 2019, 09:51:13 am
content: HiI have made some improvements to my code,here is my new settings,The I2S init functionCode:static void MX_I2S2_Init(void){/* USER CODE BEGIN I2S2_Init 0 *//* USER CODE END I2S2_Init 0 *//* USER CODE BEGIN I2S2_Init 1 *//* USER CODE END I2S2_Init 1 */hi2s2.Instance = SPI2;hi2s2.Init.Mode = I2S_MODE_MASTER_TX;hi2s2.Init.Standard = I2S_STANDARD_PHILIPS;hi2s2.Init.DataFormat = I2S_DATAFORMAT_16B;hi2s2.Init.MCLKOutput = I2S_MCLKOUTPUT_ENABLE;hi2s2.Init.AudioFreq = 44100;hi2s2.Init.CPOL = I2S_CPOL_LOW;hi2s2.Init.ClockSource = I2S_CLOCK_PLL;hi2s2.Init.FullDuplexMode = I2S_FULLDUPLEXMODE_DISABLE;if (HAL_I2S_Init(&hi2s2) != HAL_OK){Error_Handler();}/* USER CODE BEGIN I2S2_Init 2 *//* USER CODE END I2S2_Init 2 */}And this is my main functionCode:int main(void){/* USER CODE BEGIN 1 */static FRESULT myfres=1;uint32_t bt;/* USER CODE END 1 *//* MCU Configuration--------------------------------------------------------*//* Reset of all peripherals, Initializes the Flash interface and the Systick. */HAL_Init();/* USER CODE BEGIN Init *//* USER CODE END Init *//* Configure the system clock */SystemClock_Config();/* USER CODE BEGIN SysInit *//* USER CODE END SysInit *//* Initialize all configured peripherals */MX_GPIO_Init();MX_DMA_Init();MX_I2S2_Init();/* USER CODE BEGIN 2 */myfres=disk_initialize(0);myfres=f_mount(0, &fs);myfres=f_open(&myfile, "1.wav",FA_READ);myfres=f_read(&myfile,&sai_buf,sample_no,&bt);myfres=f_read(&myfile,&sai_buf,sample_no,&bt);index_buf++;h_res=HAL_I2S_Transmit_DMA(&hi2s2,sai_buf,sample_no);/* USER CODE END 2 *//* Infinite loop *//* USER CODE BEGIN WHILE */while (1){/* USER CODE END WHILE *//* USER CODE BEGIN 3 */if(refill){refill=0;myfres=f_read(&myfile,&sai_buf[index_buf%2],sample_no,&bt);}}/* USER CODE END 3 */}and this is my callback function for the I2SCode:void HAL_I2S_TxCpltCallback( I2S_HandleTypeDef * hi2s ){refill=1;HAL_I2S_Transmit_DMA(hi2s,sai_buf[index_buf%2],sample_no);index_buf++;}The problem is that the I2S callback would be called 8 times before comming back to main to refill the next buffer,Do you have any Idea? I'm really in trouble and do not know what to do

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 17, 2019, 05:19:48 pm
content: A couple remarks:* Could you show the declaration of 'sai_buf'? And the value of 'sample_no'?* I'm assuming you're doing some kind of ping-pong (double buffering), but I need to make sure you got it right.* The "f_read(&myfile,&sai_buf[index_buf%2],sample_no,&bt)" call: have you timed how long it takes? If it takes longer than the playing of one buffer through I2S, then you're screwed and that would explain your problem.

author: alizare368
author_rank: Regular Contributor
timestamp: January 20, 2019, 01:17:16 pm
content: Hithe call back function problem has been resolved but the audio output is not clear.the part of the audio output is placed in the file below.
STM32F3 OPAMP in the PGA mode - Page 1
Forum section: electronics / general

author: VanitarNordic
author_rank: Frequent Contributor
timestamp: January 16, 2019, 09:03:30 am
content: I have connected the OPAMP of the STM32F303 to the ADC input internally.The opamp has two input pins. VINM and VINP. if I decided to configure it as an amplifier and select the gain (2..16) with software. it is called PGA mode.I want to have the non-inverting amplification. then I just should connect the input signal to the VINP and the MCU itself will configure the other pin internally? I mean should I let the VINM Pin float?Has anybody worked with this feature?

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 17, 2019, 02:09:42 am
content: Yes, the - pin is connected internally when you use the PGA mode. See p. 474+ of the ref. manual.
Super close-ups of two Intel 87C51FA chips. - Page 1
Forum section: electronics / general

author: technix
author_rank: Super Contributor
timestamp: January 14, 2019, 04:41:25 pm
content: They come in a package with a quartz window, why not try take a photo of it? Each picture below is a 4000px by 3000px picture taken on my Nikon Coolpix S630TD87C51FAD87C51FA
CS4344 - Page 1
Forum section: electronics / general

author: alizare368
author_rank: Regular Contributor
timestamp: January 15, 2019, 10:08:51 am
content: HiI have a DAC (cs4344) on my board and DAC output connect to TDA2822 (audio AMP)And TDA2822 output connect to speaker computer.Why speed sound run is slow?

author: Bassman59
author_rank: Super Contributor
timestamp: January 15, 2019, 04:03:45 pm
content: Quote from: alizare368 on January 15, 2019, 10:08:51 amDoes the sample rate of the audio source (a file, perhaps) match the sample rate at which you run the DAC?
ICD3 won't program any 16-bit PIC - Page 1
Forum section: electronics / general

author: Pineapple Dan
author_rank: Contributor
timestamp: January 22, 2019, 09:50:18 pm
content: 8-bit no problem, but I have a 33fj16gs502, 30f3014, 24f16ka302 and none of them will work. I am always faced with thisConnecting to MPLAB ICD 3...Currently loaded firmware on ICD 3Firmware Suite Version.....01.54.00Firmware type..............dsPIC33F/24F/24HProgrammer to target power is enabled - VDD = 3,000000 volts.Target Device ID (0x0) is an Invalid Device ID. Please check your connections to the Target Device.I just have the PGEC,PGED, MCLR, Vdd & Vss connected. Had a 10k pullup between the mclr and Vdd as well but no luck. Never tried to program anything other than an 8bit before, am I missing something, could the ICD be shagged?

author: NorthGuy
author_rank: Super Contributor
timestamp: January 22, 2019, 10:40:16 pm
content: Most of PIC24/dsPIC33 have internal voltage regulators which require a 10 uF capacitor on Vcap. Some may also have a pin which disables/enables the regulator - look at the datasheet for this.

author: SiliconWizard
author_rank: Super Contributor
timestamp: January 22, 2019, 10:53:54 pm
content: Yes, another pitfall is not to connect the AVDD pin that most of those MCUs have. Just connect it directly to VDD (or through an LC filter, but not necessary just to program the chip). Leaving AVDD floating usually prevents it from operating properly. Got bitten once (didn't leave it floating on purpose, it was a schematic entry mistake) with a PIC24F. Same as you got, the programming tool was unable to access it. Connecting AVDD to VDD instantly solved the issue.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: January 22, 2019, 10:55:10 pm
content: Quote from: NorthGuy on January 22, 2019, 10:40:16 pmThis cap is essential for programming to work

author: JPortici
author_rank: Super Contributor
timestamp: January 23, 2019, 06:57:47 am
content: If you are unsure of the connections, there is a chapter in the datasheet called "Getting started with xxx" which has the minimal required circuit
The STM32 unwantedly locks or it goes on the bootloader mode - Page 1
Forum section: electronics / general

author: VanitarNordic
author_rank: Frequent Contributor
timestamp: January 13, 2019, 08:23:44 pm
content: I have an STM32F103C8 chip.as we know and it is written in the datasheet, if we want to load from flash, we have to pull down the BOOT0 pin with a 10K resistor.But in my case, when I pull it down, after a few flash erasing/programming, the MCU suddenly locks. Then I have to pull it up, go to the bootloader (using USART1) and erase the flash to unlock it. It was happening frequently till I left the BOOT0 pin float and after that nothing happened and everything is normal.Why this happens?, weird
Where are register 'shortcuts' defined MPlabX - Page 1
Forum section: electronics / general

author: Etesla
author_rank: Regular Contributor
timestamp: January 13, 2019, 08:04:58 pm
content: Hey guys, this post is dealing with PIC micro controllers and the MPlabX IDE.I always have trouble figuring out which things I need to type to access certain registers (PORTA, TRISA, T1CON, CCP1R, etc) in C, especially when I'm moving from mcu to mcu. For example, for one chip to access the third bit of PORTD, I type PORTD.RD0, and for another I just need to type RDO. Is there a document MPlabX is pulling from to give these definitions, and if so, where do I find it? Thanks!

author: cv007
author_rank: Frequent Contributor
timestamp: January 13, 2019, 08:31:02 pm
content: microchip/xc8/v2.00/pic/include/your_pic.hThey are trying to get you to use the LATAbits.LATA0 versions (unions), but they also have LATA0 declared as a __bit to keep old code working and anyone happy who wants to use that way.You can type LATA in your code anywhere, right click, select navigate, Go to Declaration/Definition and you will have found your header file.

author: TomS_
author_rank: Frequent Contributor
timestamp: January 14, 2019, 02:23:40 pm
content: Quote from: Etesla on January 13, 2019, 08:04:58 pmI would suggest putting some time in to learning how to use bit masks and logic operations (OR, AND, XOR). Once you know how to do that, you can manipulate anything in any way you need/want, sometimes more efficiently.Need to test whether two bits are active? You can test both bits individually using friendly names, or you can simply AND the variable with the appropriate mask and test for the appropriate resulting value. e.g.Code:#define BUTTON_1 0x01#define BUTTON_2 0x02#define BUTTON_3 0x04#define BUTTON_4 0x08#define SECRET_BUTTONS (BUTTON_1 | BUTTON_4)/* Test for super secret button combination */if ((PORTA & SECRET_BUTTONS) == SECRET_BUTTONS) {/* Do something super special */}vsCode:/* Test for super secret button combination */if (PORTA.RA0 == 1 && PORTA.RA3 == 1) {/* Do something super special */}Perhaps the first example looks more complicated, but a lot of the variables used are computed at compile time and the resulting values simply used throughout. Depending on how smart the compiler is, the second example could result in many more instructions being generated.Otherwise, what cv007 said. Right click any variable name and you can nagivate to where it has been declared. For internal register names it should take you straight to your processors header file.
2x10 pin JTAG to 2x3 pin adapter - Page 1
Forum section: electronics / general

author: cepwin
author_rank: Unknown
timestamp: January 12, 2019, 03:48:33 am
content: I purchased an Ice JTAG programmer/debugger off Ebay and when I tried to hook it up I noticed the two dev boards I have that even have a programming port (an arduino mega clone and an adafruit metro) both have 2x3 pins while the programming is 2x10.Two questions: Will this programmer even work with these boards?Is there a 2x5 to 2x3 adapter that even exists? It looks like Sparkfun used to make one but it is "retired".Thoughts? The idea was to use Atmel studio to program and debug these thingsHere is the link to the item:https://www.ebay.com/itm/302960809616

author: ataradov
author_rank: Super Contributor
timestamp: January 12, 2019, 04:07:47 am
content: This is a clone of a very outdated device, I'm not sure how well it is supported by modern tools.But here is a connection table from 10-pin JTAG to 6-pin SPI interface used on the Arduino:https://www.microchip.com/webdoc/jtagicemkii/jtagicemkii.connecting_spi.htmlYou can simply use flying wires to make a connection.

author: Nusa
author_rank: Super Contributor
timestamp: January 12, 2019, 07:15:18 am
content: Or an adapter can be purchased:https://www.ebay.com/itm/10-Pin-to-6-Pin-Adapter-Board-M-F-for-AVRISP-USBASP-STK500-G5P5/172827354795

author: cepwin
author_rank: Unknown
timestamp: January 12, 2019, 10:20:07 pm
content: Thank you both.....very helpful informationUpdate: I found an AVR Ice adapter on Ebay for $8 and free shipping that should be here in a week. Hopefully it works. I did find the parts to build an adapter cable but it cost more to ship than the actually parts so I was glad to find the adapter.Again, thank you all for your help!Update 2: So it came but it appears the device is too old to communicate with the board. It has to be a JTAG-3 programmer and I don't think that's what it is...consequently while the computer recognized it and I was able to select it in AS7 it could not read my board. Check on line (AVR Freaks) confirmed my suspicions.
PIC16C54 Help to program it. - Page 1
Forum section: electronics / general

author: sotos
author_rank: Frequent Contributor
timestamp: January 12, 2019, 07:53:36 pm
content: Help to program a PIC16C54.Can somebody please tell me if this is copy protected? I attached the bin in text file. I’m trying to program another PIC15C54 but the programmer is asking me to include the configuration which I don’t know. Isn’t the configuration written in the microcontroller when it is programmed?Also someone told me that a PIC16F54 is the same but when I try to program it, a message informs me that the program is larger than the 16F54 and refuses to program it. Programmer is ELNEC.Thanks for the help.

author: kripton2035
author_rank: Super Contributor
timestamp: January 12, 2019, 07:57:36 pm
content: this 16c54 is an OTP : one time programmable PIC you cannot reprogram it.there can be a protection. if so you cannot read it.

author: sotos
author_rank: Frequent Contributor
timestamp: January 12, 2019, 08:00:14 pm
content: I have copied it via the copy of the ELNC programmer and wanted it to be programmed in a new one.

author: wraper
author_rank: Unknown
timestamp: January 12, 2019, 08:05:28 pm
content: it's intel hex, not bin. Appears like actual data, so chip shouldn't be read protected.

author: wraper
author_rank: Unknown
timestamp: January 12, 2019, 08:09:37 pm
content: Depending on programmer it may read config fuses into the same file or it may be a separate procedure. PIC16F54 may work as replacement but it has differences. Also it has more config fuses.http://ww1.microchip.com/downloads/en/devicedoc/41220a.pdf

author: sotos
author_rank: Frequent Contributor
timestamp: January 12, 2019, 08:17:32 pm
content: I have a good working one, some 16C54 and 16F54 new ones. But unable to continue with them.

author: malagas_on_fire
author_rank: Frequent Contributor
timestamp: January 12, 2019, 08:26:41 pm
content: You could import the hex file to MPLABX and check for both microcontrollers the configuration bits are properly matches. Create for example two separate projects, one for 16C54 and another for 16F54, then compare them. In MPLABX go to Window, > Pic Memory Views.

author: sotos
author_rank: Frequent Contributor
timestamp: January 12, 2019, 08:37:40 pm
content: In the attachment there is the configuration bits that askes for them at the programing the chip, it doesn’t ask that information when I copy the good one.
Visual Pin Configurator for Nucleo-L152RE board - Page 1
Forum section: electronics / general

author: Vasi
author_rank: Regular Contributor
timestamp: January 08, 2019, 02:04:22 am
content: If it happens for someone to still use the SPL library to program STM32 microcontrollers and also have a Nucleo-L152RE board around, maybe you would like to use VPC to visually configure the pins and peripherals and generate a Makefile based project that can be compiled standalone or imported in Visual Studio Code (the VPC generates all required vscode configuration files) to be compiled, debugged, uploaded onto the board. But you also need to be Linux/UNIX user (the app is developed under Ununtu 18.04, using Lazarus+FreePascal).The VPC is open source, released under MIT license. You can do whatever you want with it, use it, develop it further, adapt it for another Nucleo-64 board that is supported by SPL driver. If you want to give it a try, tell me and I'll guide you in setting the required development environment.Repository is at gitlabhttps://gitlab.com/funlw65/vscode_nucleo_l152reAnd my blog athttps://nucleobytes.blogspot.com/And a question, was there another visual configurator for SPL library before this one?Thank you!

author: Vasi
author_rank: Regular Contributor
timestamp: January 12, 2019, 05:55:22 pm
content: Here is a tutorial how to install VPC, compile and use. No sound, sorry! Right now, youtube still working in processing the movie, so it is at its poorest quality.
Storing data in flash of micro at a specific place - Page 1
Forum section: electronics / general

author: Boscoe
author_rank: Frequent Contributor
timestamp: January 10, 2019, 10:31:49 pm
content: Hi all,I'm currently developing a product with a bootloader and an application program to go with it. For ease in production I would like to include the application binary into the C code of the bootloader to create one binary of bootloader + preinstalled application. I'm not sure how to do this as I need to store the application at a specific flash address - not just where the bootloader finishes. I'm using an STM32L052 micro.Thanks

author: lucazader
author_rank: Regular Contributor
timestamp: January 10, 2019, 10:35:44 pm
content: A simple way (so long as you are doing using flash read out protection etc):Program the bootloader and application as you normally would. to their respective locations.Then read out the flash and save to a bin/hex file. (use stlink utility or stmcubeprogrammer).

author: bson
author_rank: Unknown
timestamp: January 11, 2019, 12:44:40 am
content: Build the bootloader and application as two separate images relocated to their respective load address, and then combine the images. In a format like extended tekhex this is trivial since each record has a load address, you just need to make sure the only launch address remaining is that of the boot loader.If you need them to be able to refer to each other using symbols, then you need to compile either or the other with a different psect prefix and handle section relocation in the link script.

author: rstofer
author_rank: Super Contributor
timestamp: January 11, 2019, 04:47:08 am
content: How about just changing the Flash start address in the linker script. In fact, you could create a .section for the bootloader code and just add the bootloader.o file to the list of files. ld will handle the details.
log analysis tool - Page 1
Forum section: electronics / general

author: wrynczuk
author_rank: Newbie
timestamp: January 07, 2019, 09:20:34 pm
content: We just released our free and open source tool for log analysis. Actually, its third version already. It is very useful for embedded applications in general and IoT in particular.See it here:https://vcdmaker.orgIt allows for converting your logs to the VCD (Variable Change Dump) format files and visualizing them afterwards. It can parse any text format. All you need to do is to provide the description of your log syntax in the XML format. There's manual available along with some examples.One can also merge log files coming from different devices (whether they are synchronized or not). The log files might be even taken in different logsI encourage you to give it a try.
Eclipse AVR setup issues - Page 1
Forum section: electronics / general

author: TheWinterSnow
author_rank: Contributor
timestamp: January 08, 2019, 04:19:28 am
content: I am having two problems I have never had before although it has been awhile since I programmed MCU's. I had an old Windows computer that I programed an Arduino Mega 2560 on using eclipse. I have a newer windows 10 computer that is giving me nothing but headaches. I installed WinAVR and the AVR plugin for eclipse. My old code is being a real PITA trying to get working again but the biggest issue is that when I try to compile the code I get this error from avr-gcc.exe:"The application was unable to start correctly (0xc0000142)".Searching for this error including avr-gcc.exe results in solving issues of other windows programs and does not help my particular issue After the error pops up the console in eclipse displays:Invoking: AVR Compileravr-gcc -Wall -Os -fpack-struct -fshort-enums -ffunction-sections -fdata-sections -std=gnu99 -funsigned-char -funsigned-bitfields -mmcu=atmega2560 -DF_CPU=16000000UL -MMD -MP -MF"ATest.d" -MT"ATest.o" -c -o "ATest.o" "../ATest.c"make: *** [ATest.o] Error -1073741502"make all" terminated with exit code 2. Build might be incomplete.Have any of you had this problem and how did you fix it?On a side note I a have a project that is set to use the AVR ATMega2560. The MCU is selected (the 2560) during the creation of the the project yet I keep getting an error if I try to initialize ports higher than port D. The 2560 has way more than 4 ports obviously. This wasn't an issue that I had in my code before migrating to the new computer.

author: westfw
author_rank: Super Contributor
timestamp: January 08, 2019, 10:38:55 am
content: Winavr is ancient (2010); install the Atmel toolchain for windows, instead.
Has anyone ever wrote a SVD file? - Page 1
Forum section: electronics / general

author: technix
author_rank: Super Contributor
timestamp: January 04, 2019, 10:42:07 am
content: I am thinking about writing SVD files for some ARM7 chips like LPC2103 and AT91SAM7S512. Those files are intended to be used for 1) generate a partial device header file, and 2) for Eclipse CDT debugger’s peripheral view.1. Am I using the wrong tool for the job?2. Am I reinventing the wheels?3. Is there any tools other than a general XML editor that can accelerate this process?

author: techman-001
author_rank: Frequent Contributor
timestamp: January 04, 2019, 11:27:48 am
content: Quote from: technix on January 04, 2019, 10:42:07 am1. I think it's the right tool2. Who knows, if they exist but are not freely available, then you may have no choice.3. I use xmlcopyeditor myself, but the Rust programming language seems popular in some quarters for processing XML and other kinds of device files.https://github.com/japaric/svdis a SVD parser in Rust.I use SVD's to create a number of different Forth memory mapped files athttp://hightechdoc.net/mecrisp-stellaris/_build/html/register-generator.html#svd2forth
Does Helio P60(MT6771) include LTE,WIFI,BT and GNSS? - Page 1
Forum section: electronics / general

author: muthukural001
author_rank: Regular Contributor
timestamp: January 04, 2019, 09:43:44 am
content: Hello All,I have just gone through Helio P60 (MT6771) and see that WiFi, BT and GNSS listed under Connectivity. Does it means that it integrated LTE TRx, BT TRx and GNSS receiver ?.Thanks,Muthu
Need input to build discrete implementation of attached circuit image  - Page 1
Forum section: electronics / general

author: muthukural001
author_rank: Regular Contributor
timestamp: January 02, 2019, 06:59:26 am
content: Hi,The attached image is the high side driver of a print head driver IC for a single output. I need to implement it in discrete for a total of 64 outputs...As you know, doing the same for 64 outputs will increase the board space...So, suggest if there is any other IC which will help to reduce the board size...P.S: Each of the 64 outputs should be able to source max of 400mA and VH = 42V...Thanks,Muthu
Any good learning tools for Renesas / NEC V850 E2 Microcontrollers? - Page 1
Forum section: electronics / general

author: LetsMakeThisWork
author_rank: Newbie
timestamp: January 05, 2019, 05:29:31 pm
content: Hi I'm trying to learn about this V850. I have a copy of IDA but this V850 looks to be way more complicated than the HCS08 I just learned about.My plan is to take a existing car dashboard and add a few features. I have pulled the file and the chip is not secured/locked.I'm fairly new to this and really have only played with the Freescale HCS08. And looking back that chip was in my opinion a good one to start learning on.I found a book about it that really helped.Anyway back to the question. is there any books, list of instructions and examples, ect... that will help me understand the V850?The little endian way of storing data is already throwing me off.I found CubeStudio for this chip and think i can get the debugger hooked up and running but it doesn't look like you can see the Ram area to help determine what and where things are.Any help or information would be greatly appreciated. Thanks
Can I diagnose an NRF24L01? - Page 1
Forum section: electronics / general

author: panoss
author_rank: Frequent Contributor
timestamp: January 01, 2019, 09:55:13 am
content: Hi everybody, I wish you a happy new year!I 've been struggling for 10 days now with 2 Arduino mini pros and 2 NRF24L01 trying to make them communicate but with no success at all.I have no oscilloscope so I was wondering, is there some way to diagnose if the 2 RF modules (NRF24L01) work?I 've tried everything fromTMRH20's examples and much more, nothing worked. So I suspect that one (at least) of these modules might be faulty.So many days passed (btw I wish you a happy new year) and still haven't managed to make it work!!Is there someway to diagnose the NRF24L01 module? A test code to check if the Arduino (now I use Arduino pro minis both for transmitter & receiver) connects to the NRF module? And if it rseponds? And works?I 'm trying to make some diagnosis with this code:Code:> // http://tmrh20.github.io/RF24/// - CONNECTIONS nRF24L01 to Arduino Pro Mini//~ 1 - GND//~ 2 - VCC 3.3V !!! NOT 5V//~ 3 - CE to Arduino pin 9//~ 4 - CSN to Arduino pin 10//~ 5 - SCK to Arduino pin 13//~ 6 - MOSI to Arduino pin 11//~ 7 - MISO to Arduino pin 12//~ 8 - UNUSED#include <SPI.h>#include <nRF24L01.h>#include <RF24.h>#include "printf.h"#define CE_PIN 9#define CSN_PIN 10// NOTE: the "LL" at the end of the constant is "LongLong" typeconst uint64_t pipes = { 0xFFFFFFFFFFLL, 0xCCCCCCCCCCLL };RF24 radio(CE_PIN, CSN_PIN); // Create a Radiovoid setup() {Serial.begin(9600);printf_begin();printf("Starting...");radio.begin(); // Start up the radioradio.setPALevel(RF24_PA_HIGH);radio.setDataRate(RF24_250KBPS);radio.openReadingPipe(1, pipes);radio.openWritingPipe(pipes);radio.stopListening();radio.printDetails();}void loop() {}On the serial monitor (which btw, I must put it in 19200 baud in order to work, while in the code I set it at 9600) I get:Quote
aliexpress Pro-Mini-Module-Atmega168 clones cant ISP the Arduino away. - Page 1
Forum section: electronics / general

author: topcat
author_rank: Contributor
timestamp: December 31, 2018, 12:49:34 am
content: Hello all,I bought some clone Pro-Mini-Module-Atmega168 modules from:https://www.aliexpress.com/item/Pro-Mini-Module-Atmega168-Atmega168P-16M-16mhz-5V-For-Arduino-Nano-Microcontrol-Micro-Control-Board-Replace/32671722917.html?spm=a2g0s.9042311.0.0.27424c4dNKDWJpI was hoping it would be a cheep and convenient way to work with a Atmega168 however when I connect up my ISP header I just get error 0x0cHas anyone had any luck with these in non-Arduino applications?Regards.

author: Nusa
author_rank: Super Contributor
timestamp: December 31, 2018, 01:06:19 am
content: I don't see an ISP header on the modules you linked. Are you trying to use the serial header? Or did you make an ISP header by connecting to the appropriate pins?Picture/diagram/details of what you attempted might get us somewhere.

author: topcat
author_rank: Contributor
timestamp: December 31, 2018, 01:32:51 am
content: Hi Nusa,Yes I traced the pins from the chip (as I don't find a schematic anywhere) and connected the usual ISP suspects.I also found a page of some guy with a similar looking board who seems to make it workhttps://www.instructables.com/id/Burn-a-New-Bootloader-Arduino-Pro-Mini

author: Nusa
author_rank: Super Contributor
timestamp: December 31, 2018, 02:44:56 am
content: So did you end up using pinslabeled11,12,13,rst,vcc,gnd? 11=mosi, 12=miso, 13=sck.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2018, 04:17:29 am
content: Arduino use a capacitors in series with the reset line for programming. The arduino programmer causes a small reset pulse and then connects to the bootloader.If you use this sort of RESET pin for ISP programming the ATmega will fail to program. ISP needs direct control of reset line

author: westfw
author_rank: Super Contributor
timestamp: December 31, 2018, 06:42:16 am
content: QuoteThe "auto-reset capacitor" on an Arduino is between the Serial Interface ("DTR") and the AVR Reset. It doesn't normally interfere with ISP programming using the SPI signals and RESET direct to the AVR. (it DOES interfere with the "debugwire" debugging protocol, though. But that's a relatively high data-rate signal, while the RESET usage during ISP programming is ... more forceefully slow.)

author: topcat
author_rank: Contributor
timestamp: December 31, 2018, 03:43:43 pm
content: Hi All,Seems the issue is you need to apply vcc to the VCC pin! not as I was to the pin also labeled VCC in the Arduino programing header.Thank you for all the suggestions.