Current Server Time: 17:27 (Central Europe)

#apertus IRC Channel Logs

2018/01/28

Timezone: UTC


23:13
Bertl_oO
changed nick to: Bertl_zZ
07:29
rton
joined the channel
07:53
aombk3
joined the channel
07:56
aombk2
left the channel
08:03
Davelister
joined the channel
08:03
Davelister
changed nick to: Guest38895
08:45
Guest38895
left the channel
08:46
Niels_so
joined the channel
08:46
Niels_so
Good morning
08:48
se6astian
hi Niels_so
08:50
Rex0r
Hey Dave.
08:57
Niels_so
left the channel
09:53
BAndiT1983|away
changed nick to: BAndiT1983
10:16
Niels_so
joined the channel
10:42
Guillaume_Chooks
joined the channel
10:46
Guillaume_Chooks
Hi everybody ! Hi Dave, you can contact me at guillaume(at)chooksprod.com if you want, i'm a french near Annecy. If we organize a maker faire in Lyon it will be good to be a group to know the camera. if it's sound interesting for you !
10:47
Guillaume_Chooks
I'm working for now but d'ont hesitate to contact me !
10:52
Guillaume_Chooks
left the channel
11:05
BAndiT1983
changed nick to: BAndiT1983|away
11:05
BAndiT1983|away
changed nick to: BAndiT1983
11:42
joy_
joined the channel
11:42
joy_
Hello
11:43
joy_
left the channel
11:43
joy_
joined the channel
11:45
joy_
Is anyone here? I am interested on USB interface using FPGA project where should I start?
11:46
se6astian
hi joy_!
11:47
se6astian
if you want to apply for GSoC for this task the best starting point is completing the FPGA/VHDL challenge: https://lab.apertus.org/T871
11:49
joy_
Thank you very much...As soon I complete one of the task what should I do then
11:50
Bertl_zZ
changed nick to: Bertl
11:51
Bertl
morning folks!
11:51
Niels_so
Hi Bertl
11:52
joy_
Hello I think you are the proposed mentor of the FPGA projects
11:52
Bertl
you are correct about that :)
11:53
Bertl
make sure to deliver clean code (T871) which uses a coding style similar to the exitsting VHDL code
11:53
Bertl
note: you can also do more than one of the qualification tasks (if you feel like it)
11:54
Bertl
that together with the application for GSoC will be the basis for our selection
11:55
Bertl
do not hesitate to ask if you have any questions
11:56
joy_
Please help me out what should I learn/ do after completing the task
11:59
Bertl
when you are finished with the qualification task(s), it is probably a good idea to make yourself comfortable with the hardware (online documentation, asking here, etc) and the task you are interested in (USB interface)
12:00
Rex0r
See links to reading here - https://wiki.apertus.org/index.php/GSoC_Overview
12:02
joy_
Thank you I will contact if I face any problem
12:02
Bertl
please do so and have fun!
12:04
joy_
left the channel
12:08
Niels_so
Bertl: is completing the GSoC mandatory? Or can I contribute on FPGA tasks without?
12:09
Bertl
nothing is mandatory, you can always contribute/work on anything you like
12:09
Niels_so
ok, thank you :-)
12:12
Bertl
no problem
12:13
Niels_so
Bertl: are the FPGA chosen for a given task following this rule: Zynq for image and high-speed signals processing, Lattice for signal conversion/low-area IPs?
12:13
Niels_so
(just wondering, that's something I see on some projects as well)
12:13
BAndiT1983
changed nick to: BAndiT1983|away
12:15
manas
joined the channel
12:15
manas
Hello
12:16
Bertl
hello manas!
12:16
manas
Was the code sent good enough?
12:16
Bertl
I haven't checked it yet, but I will do so shortly
12:16
manas
I was planning to complete one more task...
12:17
Bertl
you are definitely ahead of GSoC :)
12:17
manas
Thank you
12:18
Bertl
note: having more than one qualification task is nice, but handing in a perfect one is way better
12:19
Bertl
so make sure to use proper coding style, think twice about all your decisions, if necessary, start from scratch based on the ideas you gathered on the previous attempt, etc
12:19
Bertl
in short, it is more about quality than quantity
12:20
manas
Point noted....I will check the I2C code again and remake it if needed
12:21
Bertl
I know that we do not have a coding style guide (yet) but you can always ask me if something is unclear
12:22
Bertl
hint here: writing a coding style guide might be something worth doing (benefits the project and helps you understand it at the same time)
12:23
se6astian
(2:13:09 PM) Niels_so: Bertl: are the FPGA chosen for a given task following this rule: Zynq for image and high-speed signals processing, Lattice for signal conversion/low-area IPs? <- yes thats also our approach, correct me if I am wrong, Bertl
12:24
Bertl
indeed, we selected the FPGAs based on how nicely they fit the purpose
12:25
manas
Bertyl : Regarding the I2C: apart from sda and SCL I have used a clock (system clock)of frequency 100 MHz...
12:25
Bertl
Zynq was kind of given as back then the MicroZed was the only affordable (well documented) development board with enough I/Os
12:26
Bertl
manas: that's fine, some kind of system clock will always be present, just make sure that there are no problems with synchronization/clock domain crossings
12:28
manas
So Should I also implement a frequency divider as I know that I2C works on max 400 KHz...Or the SCL will be of max 400KHz frequency
12:29
manas
That is, the frequency given from the master by the SCL line will be of 400Hz right? So should bother of the system clock frequency divider?
12:29
Bertl
I'm looking at your code right now, first thing I see there is that you want to work on your indentation
12:29
Niels_so
se6astian, Bertl : ok, thank you. Have a good afternonn!
12:29
Bertl
you too!
12:29
Niels_so
afternoon*
12:29
Niels_so
thanks!
12:30
Bertl
manas: no, the master can use anything below 1MHz (or 400kHz)
12:31
Niels_so
left the channel
12:34
BAndiT1983|away
changed nick to: BAndiT1983
12:35
manas
Okay so as the master has the control on SCL and SDA lines the frequency of the system clock in the code need not be changed..
12:39
manas
I will work on the code indentation and provide you a clean code in the future
12:39
manas
Thank you
12:39
manas
left the channel
12:40
manas
joined the channel
12:40
manas
Beryl: Please let me know if there is any error in the code
12:41
manas
I am sorry Bertl:
12:41
Bertl
yes, will go through the code tonight and provide some feedback
12:42
Bertl
it is a good idea to check here on a regular basis
13:12
BAndiT1983
changed nick to: BAndiT1983|away
13:12
BAndiT1983|away
changed nick to: BAndiT1983
13:16
manas
left the channel
13:21
manas
joined the channel
13:23
manas
Bertl : Sorry for late reply. I will surely visit here frequently
13:23
manas
Made some changes in the code indentation and added comments
13:25
Bertl
URL for the changes?
13:26
Bertl
https://raw.githubusercontent.com/Manas173/PWM-generator-and-I2C_slave/master/i2c_slave_pwm_control.vhd ?
13:26
manas
Yes correct
13:27
Bertl
here some input on that (indentation and other things):
13:27
Bertl
make sure to have a space around operators and assignments, e.g. logic:='Z'; -> logic := 'Z';
13:28
manas
Ok I am on it...replying you as soon as it is completed
13:29
Bertl
make sure to avoid unnecessary brackets, e.g. if(count>=0) then -> if count >= 0 then
13:29
manas
Okay , point noted
13:29
Bertl
use well defined macros which make the code more readable, e.g.: if clk'event and clk='1' then -> if rising_edge(clk) then
13:30
Bertl
you can, and probably should use a 4 space indentation instead of 8 spaces to keep the code within 80 characters
13:31
Bertl
keep indentation of block structures aligned, e.g. case/end case (on the same indentation level)
13:33
manas
Thats to point them out...I am working on it
13:34
Bertl
also make sure to add your copyright and put the files under a FOSS license
13:35
manas
Okay
14:14
Kjetil
Can you explain why you are driving SDA high in the read address state?
14:15
BAndiT1983
changed nick to: BAndiT1983|away
14:16
BAndiT1983|away
changed nick to: BAndiT1983
14:16
BAndiT1983
changed nick to: BAndiT1983|away
14:16
BAndiT1983|away
changed nick to: BAndiT1983
14:16
manas
Kjetil: To send an ack bit to the master
14:20
Kjetil
what if there is another slave on the bus the matches the requested address? Which will want to signal ACK (driving the bus low)
14:26
manas
The 7 bit address for each i2c slave register is a unique one so there will at max one slave address that will match
14:27
Bertl
what Kjetil tries to hint here is that the IIC bus is an open drain bus system
14:28
Bertl
i.e. you never actively put power (e.g. a '1') on the bus
14:28
Bertl
you either pull down SCL or SDA or you leave it 'flowting' (the pullups take care of the '1')
14:30
manas
A error from my side apologies...I am correcting that
14:31
Bertl
(see https://en.wikipedia.org/wiki/I%C2%B2C, http://www.ti.com/lit/an/slva704/slva704.pdf and https://www.nxp.com/docs/en/user-guide/UM10204.pdf for more details on I2C)
14:32
manas
Thank you I will correct that immedeately
14:36
Bertl
you're welcome!
14:51
manas
Commit the changes, made the changes in the code indentation and sda line floating as mentioned
14:53
Bertl
what's line 34/35?
14:55
Bertl
check code style for line 36, 62, 67, 89 and indentation for 93, 105-119, 126 and more
14:56
Bertl
also still missing a copyright notice and license
14:59
manas
That was my silly mistake Adding the copyright notice and license
15:02
Kjetil
hm.. I wonder what an expression requiring the falling edge of two clocks at the same time will syntesize to
15:08
manas
Kjetil: Sorry but do you mean why i used the falling edge of SDA and simultaneously checked for the scl to be high or not...Well its the start condition
15:09
manas
If you are asking why I used clk edge and other falling edges then its to execute the process for every clk event
15:09
manas
To do tasks such as changing the state etc.
15:10
Kjetil
nah. You have the entire statemachine driven by the rising edge of the system clock, and I genuinly wonder how the FPGA will work when you have a rising_edge/falling_edge primitive inside there that checks a asynchronous clock
15:20
se6astian
changed nick to: se6astian|away
15:25
manas
The state machine runs on the system clock but the data/address read operation is done through the edge-event of the scl line...As the synchronization of the clocks is concerned, the change of SCL line should be along with edge change of the system clock
15:26
Bertl
which is something you cannot assume with I2C
15:26
Bertl
at any time there could be clock stretching on SCL for example
15:29
Kjetil
I guess you might get a FF on the SCL line and the data outsignal from that will be used as a clock in the next FFs
15:30
Bertl
which means that when the 'system' clock is (much) higher than the expected SCL clock, you can use (over)sampling to detect transitions
15:32
Kjetil
With at edge driven implementation the meta stable region will be an issue when the 'system' clock is fast compared to the i2c clock
15:35
manas
Okay so the idea is to implement the clock of the I2C using SCL line only?
15:36
Bertl
that would certainly work for the i2c slave but pose some serious challenges for the PWM side
15:37
Bertl
of course, nothing you couldn't handle with synchronization
15:37
Bertl
but I would rather suggest to sample SCL with your system clock and act based on changes there
15:43
manas
So using a clock_divider to sample out the system clock to the clock of desired frequency (ie, max 400KHz) will rather be a better option?
15:45
Bertl
not sure what you're trying to say, but you cannot make any assumptions on SCL except that it will be below 1MHz (400kHz)
15:46
Bertl
the IIC master decides when SCL will go low and for how long (i.e. that's out of your control for the I2C/PWM task)
15:56
manas
I will look into this problem and will reply you soon enough.
15:56
manas
Thank you for guidane
15:57
Bertl
no problem!
16:17
Kjetil
manas: you might want to add spike supression "required" for fast-mode i2c in UM10204
16:48
manas
Did the changes , now the I2C runs only the scl clock and not the system clock and data transfer takes place to pwm controller which is running on system clock. Made a branch and a copyright GNU GPL license Link : https://github.com/Manas173/PWM-generator-and-I2C_slave/tree/add-license-1
16:48
manas
Kjetil : I am looking into that matter
17:02
Davelister
joined the channel
17:04
BAndiT1983
changed nick to: BAndiT1983|away
17:05
manas
Kjetil and Bertl : I will about it very soon Thanks for guidance
17:06
manas
*I will discuss about it very soon Thanks for guidance
17:06
Bertl
you're welcome!
17:06
manas
Good night
17:07
manas
left the channel
17:12
manas
joined the channel
17:13
manas
Licensed both the master and a new branch : https://github.com/Manas173/PWM-generator-and-I2C_slave/tree/branch-1 Sorry the above was deleted
17:13
manas
left the channel
17:39
Bertl
off for now ... bbl
17:39
Bertl
changed nick to: Bertl_oO
17:44
se6astian|away
changed nick to: se6astian
17:46
lenzhound[m]
left the channel
19:27
BAndiT1983|away
changed nick to: BAndiT1983
20:24
intrac
left the channel
20:27
BAndiT1983
changed nick to: BAndiT1983|away
20:45
se6astian
off to bed
20:45
se6astian
good night
20:45
se6astian
changed nick to: se6astian|away
20:49
intrac
joined the channel
21:36
Davelister
good night people
21:36
Davelister
left the channel
22:02
danieeel
left the channel
22:02
danieeel
joined the channel
22:04
danieeel
left the channel
22:04
danieeel
joined the channel
22:06
danieel
joined the channel
22:06
danieeel
left the channel
22:07
danieeel
joined the channel
22:07
danieel
left the channel
22:52
rton
left the channel