-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
shabazMay 1, 2013 10:22 PM (in response to cy.gul)
Hi,
The 'Software Setup' steps 1-6 link is broken. I looked at the zip file, but the main.c just contains essentially this:
#include <device.h>
void main()
{
Clock_Start();
PWM_Start();
for(;;)
{
}
}
Where would you have defined what connects to the count, start and clock pins on your schematic that you've shown? (I don't have a PSoC board, I'm just curious). The other files in the zip didn't seem text-readable, but I may have missed it, or is it done on the IDE somewhere?
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cypkees May 1, 2013 10:46 PM (in response to shabaz)The pic that Gagan put up is from the creator IDE. The connections are made through the schematic entry shown in that picture. That schematic and the main code are all that is needed. : )
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
shabazMay 1, 2013 10:40 PM (in response to cypkees)
Hi Chris, thanks for the information. I couldn't see from the main code nor the schematic, where the PWM depth is set. Has it defaulted to (say) 100% and requires a function call in main.c to change it?
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cypkees May 1, 2013 10:50 PM (in response to shabaz)Hey Shabaz, you would double click on the PWM component (the green and grey PWM block shown in the schematic above) in Creator and it opens a configuration dialog called a customizer for you to set parameters like Period and Compare values. Then you can change those values in code later with API calls like PWM_SetPeriod() and PWM_SetCompare() among many other things.
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
shabazMay 1, 2013 10:54 PM (in response to cypkees)
I see! It sounds straightforward and not so scary any more :-)
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
shabazMay 1, 2013 11:52 PM (in response to shabaz)
The IDE installed fine, and I was able to compile a demo program.
Just in case anyone tries it with Windows 7 64-bit: For me, when I tried to compile, it said a license had expired (although I've not installed this before), and it looks like an issue with ARM's Keil software. Followed the Help->Register->Keil process to get a license code, but the code didn't work. There was some forum where basically these steps had to be followed:
1. Go to C:\Program Files (x86)\Cypress\PSoC Creator\2.2\PSoC Creator\import\keil\pk51\9.03
2. Copy the _TOOLS.INI file to TOOLS.INI
3. go into the UV4 folder
4. Right-click and 'Run as administrator' on UV4.exe
5. Go to File->License Management, and enter the key there
6. Close the UV4.exe program, go back into the IDE, and re-do Help->Register->Keil, and the license was already there (I re-entered it there to make sure).
7. Now the compile will work!
-
-
-
-
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul May 1, 2013 10:41 PM (in response to shabaz)Hi Shabaz,
Good question!
The main.c contains only the 2 lines needed to 'start' the 2 Components - PWM and Clock, that are placed, wired, and configured on the project schematic ("TopDesign.cysch").
That's all the CPU needs to do! The rest of the design runs entirely in hardware with no CPU intervention required.
To see how the 2 Components are setup, simply double-click them to open the Component configuration window.
You can setup your global chip resources like Clocks, Pins-outs, Interrupts, DMA,etc. in their respective tabs. Here is a quick tutorial video that shows the workflow with the Pin Component as an example. http://video.cypress.com/video-library/video/PSoC-Software_PSoC-Creator/PSoC-Creator-Tutorial-Working-with-Pins/1768525420001
To get started, you will need to install the free IDE - PSoC Creator.
EDIT - thanks for noting the broken link, fixed now!
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
shabazMay 1, 2013 10:46 PM (in response to cy.gul)
Hi Gagan, Thanks for the information! It sounds great. I'll try out the free IDE to experiment, downloading it now.
-
-
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
brijesh Aug 1, 2013 10:47 PM (in response to cy.gul)Thanks To all friend.
That most things is very useful for everyone.I am the beginner for this kit I am just making a start up with kit. Can anyone send me the link for the 100 project related doc. And there are no any data related to individual. If I want to use the timer of the then their just theory part are there are no any practical example are there for using he individual part of that. So any buddy guide me related.
Thanks
Brijesh Gohel9033344829
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 16, 2013 4:23 PM (in response to brijesh)
-
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
djv30 Oct 16, 2013 4:32 PM (in response to cy.gul)Hi Im new here.I got my Pioneer kit couple of days back.
I tried this example as it was already available.and It worked just fine.
But I was curious as I wanted to try and build it on my own.
so I started placing component in creator 2.2 same as this example,Even I carefully look inside every setting of component.
I did my best to blink LED but LED is not blinking,instead it stays ON.I attached my file with this reply...
Where is the problem??I m feeling very shame as I cant build even simple project like this.I can use ready example given here but I want to do it by my self...:)-
Designtest.cydsn.zip 579.5 KB
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 16, 2013 4:21 PM (in response to djv30)-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
djv30 Oct 16, 2013 4:39 PM (in response to cy.gul)yes i did same setting...
I modified the post and added my project file too.
only difference you will notice is I used green LED.I m not getting where i did mistake...
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 16, 2013 5:59 PM (in response to djv30)Dev,
attach your project here, I can try and take a look at where you might be going wrong.
Edit - i just noticed you already posted your project, I'll take a look soon. brb
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 16, 2013 6:06 PM (in response to djv30)Hi Dev,
I found the source of your issue -
The main.c file in your project needs to lines of code to 'start' the hardware Components.
All Components in PSoC need to be explicitly started with a simple API. This is provided so the user can have complete control over all of the hardware Components and chose when to start/stop them.
PWM_Start();
Clock_Start();
Place these 2 lines in the initialization section on the top of your main.c
This is what your entire main.c should look like -
#include <device.h>
void main()
{
/* Place your initialization/startup code here (e.g. MyInst_Start()) */
Clock_Start();
PWM_Start();
/* CyGlobalIntEnable; */ /* Uncomment this line to enable global interrupts. */
for(;;)
{
/* Place your application code here. */
}
}
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
djv30 Oct 17, 2013 2:37 AM (in response to cy.gul)Yes...it's now working...
I didnt aware about editing in main file.I will take care next time,(where can i get info about this kind of syntax for programming,I mean is there any guide on Cypress site or so??
Thank you so so much for quick reply...now I will head towards new project
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 18, 2013 12:22 PM (in response to djv30)Dev,
i would recommend looking at these projects, they include good lab exercises with full step-wise details on how to build these projects:
67 06-Aug-2013 PSoC 4 Getting Started Lab 1 (LED Blinky) 68 07-Aug-2013 PSoC 4 Getting Started Lab 2 (PWM LED) 69 08-Aug-2013 PSoC 4 Getting Started Lab 3 (CapSense UART) 70 09-Aug-2013 PSoC 4 Getting Started Lab 4 (ADC)
-
-
-
-
-
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
vaithi13 Oct 21, 2013 3:49 AM (in response to cy.gul)hello sir, i am vaithilingam kumaravel. i am new for PSoC 4 family and i have the board. how to start the code and designing.i download and installed PSoC Creator 2.2 successfully. 100 project 100 day, i downoad the attachement but not opened.the following error is shown.
Error: prj.M0051: Unable to open the workspace "C:\Users\VAITI\AppData\Local\Temp\Rar$DIa0.397\Blinking LED.cywrk": (Invalid character(s): $). Address the error and try again.
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Oct 21, 2013 6:21 PM (in response to vaithi13)Hi kumaravel,
looks like you haven't unzipped the entire project on your harddrive. Please be sure to extract all of the contents of the project's .zip file to a folder on your computer. Then open the project in PSoC Creator.
-
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
Jonathanrifaut Apr 14, 2014 4:52 AM (in response to cy.gul)Hi,
Heu, maybe a stupid question, but why do you draw a resistor and a led ? You don't need it to blink a led. I follow the Lab 01 from Cypress and there is no led and resistor... Why ? Thank you.
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
cy.gul Apr 16, 2014 3:05 PM (in response to Jonathanrifaut)the components in blue color are for visual reference only, intended to make it easier for someone to look at your schematic and figure out whats going on.
these components are external to the PSoC and do not factor into the project build, merely for documentation purposes!
-
Re: PSoC 4 Pioneer Kit Community Project#01 - Blinking LED
Jonathanrifaut Apr 16, 2014 3:27 PM (in response to cy.gul)Ho great,
Thank you. It was to my idea, but I would just be sure.
-
-
To kick-start our 100 Projects in 100 Days community effort around the PSoC 4 Pioneer Kit, today I'm posting a simple "Blinking LED" project.
This is a very simple project that will help you get started with your first design for the PSoC 4 Pioneer Kit.
Project Schematic:
Actual screenshot from PSoC Creator schematic (TopDesign.cysch)
In this design, a PWM Component drives the Pin Component which is connected to the Blue LED on the Pioneer Kit. The PWM modulates to make the blue LED blink at regular intervals
Hardware connections on the Kit:
- Blue LED - P0[3] (this is internally wired, no extra connections required)
Software Setup:
- See steps #1 - #6 from the main post here
Project Files:
- Blinking LED.cywrk.Archive01.zip